Prompt Engineering
The discipline of designing and refining input prompts to elicit more accurate, reliable, and useful responses from AI language models.
What Is Prompt Engineering?
Prompt engineering is the practice of structuring text inputs to guide a language model toward producing desired outputs. Because LLMs are sensitive to how instructions are phrased, a well-crafted prompt can dramatically change response quality without any model training. Techniques range from simple instruction clarity to complex patterns like chain-of-thought, few-shot examples, and role assignment.
Key techniques include: zero-shot prompting (direct instruction with no examples), few-shot prompting (providing 2–5 input-output examples), chain-of-thought (asking the model to reason step-by-step before answering), system prompts (persistent instructions that shape model behaviour throughout a conversation), and structured output prompting (instructing the model to respond in JSON or another format).
Why It Matters
Prompt engineering is the fastest way to improve LLM performance without spending on compute. For many tasks, the right prompt closes 80–90% of the gap between a mediocre and excellent AI output. As models become more capable, prompt engineering evolves — but the skill of communicating intent clearly to AI systems remains foundational.
Real-World Examples
Chain-of-Thought Math
Adding "Think step by step" to a math problem dramatically increases accuracy, because it forces the model to surface intermediate reasoning rather than guessing the final answer.