Prompt Engineering
Effective Prompting for
Generating High-Quality Output
Effective Prompting for
Generating High-Quality Output
Written by Martin Ågren - October 20, 2026
Definition = Writing effective prompts in order to get high-quality output from AI models
Experiment / Learning by doing = Try different approaches and draw conclusions - This improves your prompt engineering skills
Preventing AI hallucinations = This is an important part of prompt engineering, which improves factual correctness in output.
Ambiguity = Input should NOT be open to misunderstanding. "Tell me about Java": Refers to Indonesian island or programming?
Chain of thought (CoT) = Often better answer - Avoid for reasoning models - "Reason step-by-step. Finish with final conclusion"
Commands / Hotkeys = Define commands. Example: --s = "Write short answers in this discussion!" - Or: AutoHotkey (Windows)
Constraints = Define boundaries, limitations, and what the AI model should avoid
Decomposition / Prompt decomposition / Stepwise promptning = Break down a complex task into several smaller steps
Detailed Enough = The prompt "Improve my text" could work well (if you are lucky) but is very vague. Improve how?
English = Often best to communicate with AI in English, since English is the most common language in its training data
Examples = Provide examples of what high-quality output could look like
Format = Describe desired output format - Example: Short, bulleted list / Table / XLSX file
Goal = Define desired outcome
Iterate = Ask follow-up questions and demand better answers - Continue chatting until you are satisfied
Pruning = Remove previous history to avoid confusing the LM with distracting context: Hover over input, Click Edit 🖋️, cut off.
Reference material = Paste reference text (using triple quotation marks as delimiters) or upload file so AI has enough info
Self-correction = Ask AI to check its own output. Example: "Check your previous answer. Is it correct? Needs improvement?"
Short = Short input, short output, short chat - But long enough so that AI has enough context to produce good output
Target audience = If AI should write a text: You could define target audience + ask for language adapted to that audience
Theme / Role = In prompt 1. Example, theme: "Let us discuss prompt engineering". Example, role: "Act like a senior AI expert"
Tone = Define the desired style or tone - Example: "A casual but still professional tone"
Tool use = Tell AI to use a specific tool, if it likely will improve output quality - Example: "Search multiple reliable websites"
You = Explain who you are, situation, what is important, etc
OpenAI = Prompt engineering