Free Learning Resource
A practical reference for writing clear prompts for LLM applications.
ROLE
You are a data science instructor.
TASK
Explain linear regression to beginners.
CONTEXT
The learners know Python basics.
CONSTRAINTS
Use a simple example and avoid advanced mathematics.
OUTPUT FORMAT
Give the explanation in five numbered steps.
| Component | Purpose |
|---|---|
| Role | Sets expertise or perspective |
| Task | States exactly what must be done |
| Context | Provides relevant background |
| Constraints | Controls scope, style or length |
| Examples | Shows the expected pattern |
| Output Format | Defines the desired structure |
Example:
Input: Product is damaged
Output: Complaint
Example:
Input: Delivery was late
Output: Complaint
Now classify:
Input: The product arrived on time.
Output:
Explain Generative AI to MBA students in 200 words,
using one business example and a five-point structure.