WHAT IT IS
The discipline covers prompt structure (role, task, context, format, constraints), in-context examples (few-shot), reasoning scaffolds (chain-of-thought, tree-of-thought, ReAct), decomposition (planner-executor patterns), tool-use formatting, system-prompt engineering for product applications, and guardrails against injection and jailbreak. The Anthropic prompt library, OpenAI prompting guide, and Google prompting guide are the canonical references.
HOW IT WORKS
At production scale, prompts are versioned like code and evaluated against golden datasets and LLM-as-judge scoring. Regressions are caught before users see them. Prompt engineering is therefore evaluation engineering in disguise — the prompt is the interface, but the test harness is the discipline.
WHEN TO USE
Invest in prompt engineering when an LLM is in production, when quality/variance matters, or when the same prompt is reused across large volumes of inputs or users.