concept

Prompt engineering

Prompt engineering is the practice of designing input text that reliably steers a large language model toward a specific output.

Prompt engineering is the discipline of writing, testing, and refining the instructions sent to a large language model so it produces the output you want. It combines linguistic precision (clear verbs, explicit constraints), structural design (system vs. user messages, examples, output format), and empirical iteration (A/B test prompt variants on real inputs). Strong prompt engineering reduces hallucinations, lowers token cost, and makes model behavior predictable across runs. It is now a core skill for any team building on top of GPT, Claude, Gemini, or open-source models.

When to use prompt engineering

Common mistakes

FAQ

What is prompt engineering?

Prompt engineering is the practice of designing input text that reliably steers a large language model toward a specific output.

When should I use prompt engineering?

Productionizing any LLM feature (chatbots, agents, content generation, classification). Migrating between models (the same prompt rarely performs identically on GPT and Claude). Reducing cost — a tighter prompt often beats fine-tuning for ROI.

What are the most common mistakes with prompt engineering?

Treating prompt engineering as a one-shot task instead of an iterative loop with evals. Stuffing the system prompt with rules instead of supplying examples. Skipping output format constraints (JSON schema, bullet count, max length).

Sources

Last updated: 2026-06-01. Raw markdown: https://promtable.com/glossary/prompt-engineering.md.