Phase 1 · Building with LLMs · Prompting
Prompt fundamentals
Clear instructions, context and constraints: the 80% of prompting.
Open this lesson Create a free account
Why it matters
The prompt is the main control you have over a model. The same model can return a vague paragraph or exactly the output your code needs, and the difference is almost always in how clearly the task was described. Prompting has more in common with writing a good creative brief than with learning secret phrases, and you've written plenty of briefs for agencies and freelancers.
What you'll be able to do
- Rewrite a vague request as a prompt with a task, context, constraints and an output format
- Separate instructions from the material the model works on, using XML-style tags
- Build prompts from a Python template so every request is worded the same way
- Test a prompt on several inputs, and handle replies that don't follow the format
Before this lesson
Next in this phase: System prompts and roles