AI Newsway
Back to glossary

Prompt Engineering

Large language models

Prompt Engineering is the practice of shaping the input given to a language model so the output is accurate, consistent, and usable by downstream software. Because a model responds to wording, order, and format, small changes to an instruction can change the answer as much as switching models. Established techniques include few-shot prompting, which supplies worked examples; chain-of-thought prompting, which asks the model to reason step by step before answering; and system prompts, which fix the role and rules for an entire session. Teams also constrain the output shape, asking for JSON that matches a schema so the response can be parsed rather than read. In practice this looks like product work: OpenAI, Anthropic, and Google all publish prompting guides, and tools such as LangChain or PromptLayer version prompts the way code is versioned. The pitfall is treating a prompt as a permanent fix. Prompts that work on one model version can degrade after an update, so teams keep evaluation sets and rerun them whenever the model or the prompt changes. Prompt engineering also has limits: when a task needs knowledge the model never saw, retrieval or fine-tuning solves what wording cannot.