Context Engineering and Prompt Engineering
Context engineering and prompt engineering are the two core disciplines for building applications with large language models. Prompt engineering focuses on crafting the textual instructions given to a model to produce desired outputs. Context engineering is the broader practice of designing, curating, and maintaining the entire information environment the model operates within — including system instructions, retrieved documents, conversation history, tool definitions and outputs, memory, and dynamic state[^c1][^c2]. The distinction has been compared to the historical split between user interface (UI) and user experience (UX) design in web development: prompt engineering optimizes the surface interaction, while context engineering architects the information ecosystem that makes that interaction effective[^c3].
The term "context engineering" gained prominence in mid-2025 after amplification by Shopify CEO Tobi Lutke and AI researcher Andrej Karpathy, who described it as "the delicate art and science of filling the context window with just the right information for the next step." Anthropic, GitHub, Thoughtworks, and other major technology organizations have since published guides positioning context engineering as the natural progression and evolution of prompt engineering[^c4]. By 2026, the discipline had become recognized as the central engineering concern for production AI systems, particularly those involving agents operating over multiple turns of inference with tool use and memory.
The shift from prompt engineering to context engineering reflects a change in the kinds of AI systems being built. Early LLM applications were predominantly single-turn tasks where all necessary information could fit within a single prompt. Modern AI agents operate over multiple turns, accumulate state, use tools, make decisions, and maintain memory across extended sessions — generating data with every inference cycle that must be cyclically refined[^c6]. In these systems, the prompt typically constitutes 5 to 10 percent of what fills the context window; the remainder is managed by context engineering[^c7]. As an industry consensus, prompt engineering remains essential for instruction quality, but context engineering addresses the more fundamental challenge of information architecture for production systems[^c5].