Communicating with LLMs
18 minLesson 4 of 14
Anatomy of a Good Prompt
Learn the components of effective prompts for real LLM-powered products
Learning goals
- •Understand the CRISPE framework for structuring prompts
- •Learn best practices for clarity and specificity
- •Know how to use delimiters and formatting effectively
The CRISPE Framework
A strong prompt often includes these elements:
C - Context Background information the model needs to understand the task.
R - Role Who the model should act as (expert, assistant, character).
I - Instructions Clear, specific directions for what to do.
S - Specifics Details about format, length, style, or constraints.
P - Persona Tone and voice characteristics for the response.
E - Examples Sample inputs and outputs to demonstrate expectations.
Prompt Structure Best Practices
Be Specific, Not Vague ❌ "Write something about dogs" ✅ "Write a 100-word informative paragraph about Golden Retrievers' temperament for first-time dog owners"
Use Clear Delimiters Separate different parts of your prompt with clear markers:
Context: [Your context here]
---
Task: [Your task here]
---
Format: [Expected output format]Order Matters Put the most important information at the beginning and end of prompts. Information in the middle may receive less attention (the "lost in the middle" problem).
Be Explicit About Format If you want a list, say "as a numbered list." If you want JSON, specify the schema.
Common mistakes
×Being too vague—'write something good' gives the model no direction
×Overloading with instructions—too many competing requirements confuse the model
×Assuming context—the model doesn't know your previous thoughts or projects
×Forgetting format requirements—if you need structured output, specify it explicitly
Key takeaways
+Structure prompts with context, role, instructions, specifics, and examples
+Be specific about format, length, tone, and audience
+Use delimiters to clearly separate different parts of complex prompts
+Put critical information at the beginning and end, not the middle