Identify every activity below that is context engineering rather than prompt engineering
Context engineering changes what arrives at the model (retrieval knobs, history compaction, tool-output routing, schema enforcement).
Think of it like cooking. Prompt engineering is rewriting the recipe: changing the words, adding more example steps, telling the chef in clearer English what to do. Context engineering is changing the kitchen: which ingredients are on the prep table, how much pantry stock the cook can see, whether the spice rack got reorganized, what shape the serving plate is. The recipe in a different kitchen produces a different dish. In this question, anything that changes what is on the prep table (retrieval, history compaction, tool outputs, output schema) is the kitchen. Anything that changes the recipe text itself (system prompt wording, chain-of-thought examples in the instruction) is the recipe.
Concept explanation~2 min read
Everything you need to truly understand this topic: intuition, mechanics, step by step explanation, code, formulas, and worked example. Click to expand.
Concept explanation~2 min read
Everything you need to truly understand this topic: intuition, mechanics, step by step explanation, code, formulas, and worked example. Click to expand.
Prompt engineering and context engineering get confused for each other because they both feed the same model and both can make it perform better. They are not the same discipline. They operate at different layers of the pipeline, use different tools, have different ownership inside production teams, and fail in different ways. Mixing them up at debug time is one of the more expensive mistakes a team can make.
The operational test is simple. If your change diffs the literal text of the instruction the model reads, you are doing prompt engineering. If your change diffs the assembly logic that decides what arrives at the model, retrieval, history, memory, tool routing, schema enforcement, you are doing context engineering.
This multi-select question is a useful classifier because four of the six options sit cleanly in context, two sit cleanly in prompt, and one (the Pydantic schema) is the textbook subtle case that trips people up. Walking through them clarifies the line and surfaces the production reasons it matters.
The composition versus wording line
Prompt engineering is editing the string. Few-shot examples, role priming, output-formatting instructions in prose, numbered rules, all of these are diffs on the literal text that gets serialized to the model. They are usually owned by domain-specialist authors or by anyone working in a prompt-management surface (LangChain Prompt Hub, Anthropic's system parameter, OpenAI's playground).
Context engineering is editing the pipeline that assembles the prompt at runtime. Retrieval policy decides what chunks land in the context block. The summarizer decides what conversation history looks like above the budget threshold. The tool-output router decides whether a 50k-token API response gets passed through, summarized, or truncated before re-entering context. The schema-enforcement backend decides whether output compliance is enforced by sampler constraints, by validate and retry loops, or by the model alone reading prose. Each of these is a composition-time decision, owned by platform engineers and shaped by infrastructure choices.
The two layers compose. The same prompt template with a different retrieval policy produces different model output. The same retrieval policy with a different system prompt also produces different output. Both axes are real and both matter; the discipline of distinguishing them is what lets a team debug failures correctly and pick the right lever for a fix.
Situations where this technique stops working.
2–4 min · Everything important, quickly.
| Activity | Layer | Where the change lives |
|---|---|---|
| Rewording the system prompt | Prompt | The system prompt string |
| Adding few-shot examples | Prompt | The user or system prompt string |
| Tuning rerank top-k | Context | The retrieval pipeline config |
| History compaction strategy | Context | The conversation-management layer |
| Tool-output summarization | Context | The tool-result post-processing pipeline |
| Pydantic schema for output | Context | The constraint-decoding or validation backend |
Real products, models, and research that use this idea.
- Anthropic's prompt engineering guide is explicitly about string-authoring patterns (XML tagging, role priming, output formatting); their context engineering recommendations live in separate docs about prompt caching, tool use, and long-context strategies.
- LangChain Prompt Hub stores prompt templates (prompt engineering); LangChain's retrievers, memory, and output parsers are context-engineering primitives.
What an interviewer would ask next. Try answering before peeking at the approach.
QHow do you tell whether a quality regression is a context problem or a prompt problem?
Replay the failing input with a clean assembled prompt. If the model still fails, it is a prompt problem (the instruction shape is wrong). If the model succeeds, the composition assembled something different in production (a context problem). Logs of the assembled prompt are required for this diagnosis.
Red flags & common mistakes
The phrases that signal junior thinking. Click to expand.
Red flags & common mistakes
The phrases that signal junior thinking. Click to expand.
Treating chain-of-thought examples in the prompt as context engineering because they 'add content.' They live in the instruction string, that is prompt engineering. The line is composition versus wording.
60 second bullets to scan on the way to the call.
The composition vs wording line that defines the two disciplines
Two examples of each that show up in a typical 2026 stack
Primary sources. Browse if you want the original framing.
Same topic, related formats. Practice these next.