Prompt Engineering
The AI does what you mean, not what you say. So say it well.
▶ the lesson · narrated sketch video · tap for sound
the intro
Prompt engineering is the skill of writing instructions that get useful output out of AI models. The core moves never change: be specific, show an example, give the model a role, and iterate on the result. It is less magic, more clear communication.
the sample
same request, different results
bad: "write code"
good: "write a TypeScript function
that debounces user input,
with unit tests"fun fact ✦
“Prompt engineer” became a real job title with a real salary. Your typing finally pays off.
the docs
the deep dive
the ideas behind the video — concepts, diagrams, a walkthrough and the traps to avoid
The model cannot ask you follow-up questions, so every detail you leave out gets filled in with a guess. Prompting is just removing the guesses: say who the model is, what exactly you want, and what done looks like. The good news is that this is a skill with fast feedback — change one line, rerun, compare.
every missing detail is a guess
key terms
role
A persona line that steers tone, vocabulary, and depth in one sentence.
"You are a senior reviewer."few-shot
Teaching by example: give two input-output pairs and the model copies the pattern better than it follows specs.
2 examples > 2 paragraphs of ruleschain of thought
Ask for reasoning before the answer. Accuracy climbs on math and multi-step tasks because each step gets attention.
"think step by step" is a baselinedelimiter
Markers that separate your instructions from the data, so user text cannot blur into commands.
triple quotes, XML tags, ###how it works
- 1State the role
One line: who the model is and how expert it should sound.
- 2Describe the task exactly
Say the format, length, and audience you want. Specific beats polite every time.
- 3Show an example
One or two input-output pairs teach the pattern faster than paragraphs of rules.
- 4Separate the data
Put the text to process inside quotes or tags so it cannot read as instructions.
- 5Iterate on failures
When output misses, fix the prompt like a failing test: change one variable at a time.
the code, explained
a prompt with all four slots filled
side by side
one mega-prompt
- one shot at everything
- middle steps quietly dropped
- a restart redoes all the work
chained prompts
- full attention on each step
- each stage is debuggable
- more calls, more latency
Models are trained to be agreeable, so "is this good?" gets a yes. Ask "what is wrong with this approach, specifically?" and watch the real review appear. Phrase questions so that disagreement is the expected answer.
quick answers
Do prompt techniques go stale?
Models get better at intent, so tricks age out. But specificity, examples, and iteration have worked on every model shipped so far.
System prompt or user message?
Standing rules go in the system prompt, per-request content from the user. Mixing them makes both harder to change.
Is "prompt engineer" a real job?
As a standalone title it is fading. As a skill it is now table stakes for anyone building on models.
quick hits about Prompt Engineering
short answers · interviews, tips, trivia & hidden gems