blog.dopana

Back

Every capability jump in AI agents followed the same pattern: practitioners hit a wall, found the layer that was actually the bottleneck, and turned that layer into an engineering discipline. Three layers, three disciplines — Prompt Engineering → Context Engineering → Harness Engineering. Understanding this ladder explains not only where agents came from, but where the industry is going next.

01 Prompt Engineering2022–2023make the model answer well02 Context Engineering2023–2025feed the model the right context03 Harness Engineering2025–nowmake execution reliable

Stage 01 · Prompt Engineering (2022–2023)#

Where it came from#

ChatGPT’s launch in November 2022 made model capability visible to everyone for the first time — and exposed a strange fact: the quality of the output depended heavily on the wording of the input. The same model, asked the same question in two different ways, could produce brilliance or garbage. Prompt became the highest-leverage part of the whole stack.

The earliest agent prototypes were born here: one long prompt instructing the model to act as an “autonomous task-completing assistant.” The prompt was, at the time, the only programmable interface to model behavior.

Core techniques#

  1. Few-shot examples — show the model a handful of demonstrations and let it imitate the pattern.
  2. Chain-of-Thought — “think step by step” elicits an explicit reasoning chain and measurably improves complex tasks.
  3. System prompts / role setting — a system-level instruction constrains persona, boundaries and output style.
  4. Structured output — demand JSON or XML so the result can be consumed by programs.

Why it stopped being enough#

  • No memory — every conversation starts from zero; nothing carries across sessions.
  • Knowledge cutoff — the model knows nothing after training, and none of your private data.
  • Can’t act — it only generates text; it can’t call an API or touch a file.
  • Limited window — even the perfect prompt can’t fit an unbounded task; long tasks lose focus.

[!NOTE] The bottleneck was not “how you ask” but what the model can see and what it can do. That realization opened the second era.

Stage 02 · Context Engineering (2023–2025)#

Why context is the new memory#

A model’s weights are frozen at training time. At inference, everything the model “knows” about your situation is whatever fits inside the context window. That makes the context window the agent’s operating memory — and assembling it well (what goes in, how much, in what order, when to discard) became an engineering discipline of its own: context engineering.

The shift in one sentence: from crafting the instruction to designing the information environment around the instruction.

The three pillars#

PillarWhat it doesWhat it solves
RAG (Retrieval-Augmented Generation)Chunk documents into vectors, retrieve the most relevant pieces at question time, inject them into the contextKnowledge freshness and private data
MemorySummarize old turns for short-term working memory; vectorize facts and preferences for long-term storage“Starting from zero every session”
Tool UseModel emits structured call instructions (Function Calling, MCP); the program executes them and feeds results backInteraction with the real world
|tool call||results|User queryRetrieverVector DBContext assemblerMemory storeLLMTools / APIsAnswer

RAG fills the window with relevant knowledge, memory keeps history and preferences alive across sessions, and tool use lets the model reach outside itself. Get the assembly right — key facts positioned to avoid “lost in the middle,” stale history compressed away — and a frozen model behaves like a system that learns.

Stage 03 · Harness Engineering (2025–now)#

From a prompt to an engine#

A harness is the entire engineering system wrapped around the model: the planning loop, tool execution, sandboxing, permission control, error recovery, observability. The model supplies intelligence; the harness supplies reliability.

The framework timeline tells the story:

2023AutoGPT erasingle-file loop scripts2024FrameworksLangChain / LangGraph /CrewAI2025Engineered harnesssandbox, permissions, contextmgmt2026StandardizationMCP / A2A protocols
  • 2023 · AutoGPT era — a goal in, an autonomous think–act loop out. It proved the model + loop + tools combination could work, and proved it was wildly unstable.
  • 2024 · Frameworks — LangChain, LangGraph, CrewAI turned agents into composable graphs and role teams: deterministic code and LLM steps in one auditable structure.
  • 2025 · Engineered harnesses — products like Claude Code and OpenClaw made sandboxing, permission gates and context management first-class citizens. The harness became the product.
  • 2026 · Standardization — protocols like MCP (uniform tool access) and A2A (agent-to-agent communication) turn agents into composable infrastructure.

Representative products#

  • AutoGPT (2023) — the pioneer. Given a goal, it decomposed and executed autonomously in a minimal harness. Its value was proof-of-possibility more than reliability.
  • ACPAgent — protocol-first collaboration: multiple agents discover, delegate and exchange context over standard agent-communication protocols. The engineering center of gravity moves from the single inner loop to the collaboration network.
  • OpenClaw — an open-source personal agent harness: runs in a local sandbox, connects to messaging channels, manages long-term memory and tool permissions. It productizes exactly what harness engineering is about — engineering certainty.

[!TIP] The deeper pattern across all three stages: as models get stronger, the harness absorbs more of the engineering certainty. The model handles intelligence; the harness handles everything that must not fail.

The ladder in one table#

EraDisciplineCore questionMental model
Prompt EngineeringInstruction craftHow do I ask?Prompt as program
Context EngineeringInformation assemblyWhat can the model see?Context as memory
Harness EngineeringSystems reliabilityWill it get the job done, safely?Harness as operating system

Each layer never replaced the previous one — it absorbed it. Prompts still matter, but inside a context strategy; context still matters, but inside a harness. The abstraction level keeps rising, and the essence stays the same: make the model do things reliably.

What’s next? Multi-agent collaboration, verifiable execution, and an “agent economy” where agents transact with each other. Each will demand a new engineering layer on top — which is exactly how this story has always gone.

References#