The world’s first unified interface for agent harnessesOpen Source4.6kPowered by UHP

InsightsNov 25, 20268 min read

The bottleneck keeps moving: from prompt engineering to graph engineering

Richard traces five shifts in AI engineering, from prompts and context to harnesses, loops and graphs, and explains why the next bottleneck is composition.

Richard's original cover for The bottleneck keeps moving: from prompt engineering to graph engineering.

The bottleneck keeps moving

Originally published on X on November 25, 2026. This is my perspective on the shift toward graph engineering, republished here with the original illustrations. The animated overview comes from my original announcement.

AI engineering has had five names in four years: prompt engineering, context engineering, harness engineering, loop engineering and, since July, graph engineering.

It's tempting to call them rebrands. They aren't. Each name appeared because the previous bottleneck got solved and a new one showed up right behind it.

And the gaps keep shrinking:

  • Prompt engineering had the stage for about two and a half years.
  • Context engineering got eight months before "harness engineering" arrived.
  • Harness engineering got four months before "loop engineering" did.
  • Loop engineering got six weeks before "graph engineering" took over the conversation.

Each layer also wraps the one before it. A loop runs a harness, a harness assembles the context, and the context still contains a prompt. Nothing died; the bottleneck moved outward.

Below: how each layer works, the techniques that defined it, where it broke, and what I think graph engineering actually has to mean.

Richard's original animated overview of the five bottlenecks: prompt, context, harness, loop and graph engineering.

1) Prompt engineering (Nov 2022 – Jun 2025): the bottleneck was wording

The job: get the best answer out of one model call by choosing the words.

ChatGPT launched in November 2022 and put a model in front of everyone. People quickly found that the same model gave very different answers depending on how you asked. By 2023, "prompt engineer" was a job title, with listings paying up to $335K.

Richard's original animation showing a prompt entering a model and producing an answer.

The techniques that defined it:

  • Role: tell the model who it is ("You are a contracts paralegal").
  • Instructions: say exactly what to extract or produce.
  • Few-shot examples: show two or three worked examples, so the model copies the format and handles the edge cases.
  • Chain-of-thought: ask it to reason step by step, or to quote its evidence before answering.
  • Structured output: a JSON schema or XML tags, so code can parse the answer.
  • Self-consistency: sample several answers and keep the majority.

Where it broke: a prompt can only shape what the model already knows. Ask about clause 14.2 of a contract it never saw, and a well-worded prompt gets you a well-worded guess. Meanwhile, instruction-tuned models from GPT-4 onward got good at following plain requests, so clever wording stopped being an edge.

Defined by: ChatGPT, GPT-4 (Mar 2023), LangChain (Oct 2022), and endless prompt libraries.

If you build today: keep prompts short and structured. The leverage moved to what the model sees and does.

2) Context engineering (named June 2025): the bottleneck was information

The job: put exactly the right information in front of the model on each turn.

A model can only reason over what it sees. Shopify's Tobi Lütke popularized the term in June 2025, and Karpathy co-signed it a week later.

Everything competes for one window: the system prompt, tool definitions, memory, retrieved documents, the conversation so far and the user's question.

Richard's original animation showing retrieved documents, tools and memory assembled into the model context.

The techniques that defined it:

  • RAG: split documents into chunks, embed them, store them in a vector database, and retrieve the top-k chunks closest to the query.
  • Reranking: retrieve wide, then let a second model reorder the results by relevance.
  • Hybrid search: combine keyword search (BM25) with vectors.
  • Query rewriting: turn the user's question into better search queries.
  • Compaction: summarize old turns and evict stale tool output so the window doesn't fill up.
  • MCP (Nov 2024): a standard way for models to pull in tools and data from other systems.
  • Long context: million-token windows (Gemini 1.5, Feb 2024) let you paste whole documents.

Where it broke: top-k vector retrieval. I learned this firsthand: I built a vector database in 2023 and pivoted six months in.

Similarity search finds text that looks like the question, not the facts a task needs. Ask "which of our suppliers are affected by the new EU packaging rule?" and the closest chunks are all about the rule. The fact that answers it, that one supplier ships from Rotterdam, sits in a chunk that never mentions the rule, so it's never retrieved.

For a chatbot, similar is close enough. For an agent on step 7 of a 20-step task, the missing fact is the failure. Bigger windows didn't fix that; they made it cheaper to stuff in more of the wrong things.

Defined by: vector databases, RAG frameworks, MCP and long-context models.

If you build today: treat retrieval as one input to context, not all of it. Decide what each turn needs before you search.

3) Harness engineering (named Feb 2026): the bottleneck was execution

The job: build everything around the model that lets it act reliably, not just answer.

OpenAI's "Harness engineering" post in February 2026 described a team whose main job had become designing the environment around Codex rather than writing code.

Richard's original animation showing an agent harness coordinating model calls, tools, permissions and verification.

What a harness does on every turn:

  • Tools: defines what the model can call, with schemas it can follow.
  • Sandbox: gives it real files and a shell to act in.
  • Permissions: decides which calls run automatically and which need a person.
  • Result handling: a 48K-token log goes to a file, and the model gets a short summary instead.
  • Retries: catches failures and feeds the error back.
  • Subagents: hands side tasks to a fresh context, so the main one stays clean.
  • Verifiers: run the tests or check the schema before a step counts as done.
  • Skills and memory: load instructions and past lessons only when they're relevant.

Notice how much of a good run is harness code, not model intelligence. Same model, better harness: more tasks finished, fewer tokens spent.

Where it broke: the human was still the outer loop. A harness finishes a run and waits. You read the result, write the next prompt and start again, sometimes dozens of times a day.

Defined by: Claude Code (Feb 2025), Codex CLI (Apr 2025), Hermes and OpenCode.

This is where serious teams are today. Harness engineering went mainstream this year.

If you build today: invest in verifiers first. A harness without a check is just a faster way to be wrong.

4) Loop engineering (named June 2026): the bottleneck was autonomy

The job: take the human out of the outer loop, safely.

Addy Osmani popularized the term in June 2026.

Richard's original animation showing a harness repeatedly running until a completion check or stop condition.

How a loop works:

  • Trigger: it starts on a schedule, an event (a new issue, a failed build) or a goal, not on your prompt.
  • Turns: it runs the harness turn after turn, with no prompt in between.
  • State: it writes progress to a file or checkpoint, so a crash or a restart resumes the job instead of starting over.
  • Stop conditions: the stop is a real signal, never the agent's word.

The stop conditions are the whole craft:

  • Completion check: the tests pass, or a separate verifier model agrees.
  • Budget: a cap on turns, tokens or dollars.
  • No-progress detector: the same call three times in a row ends the run.
  • Escalation: after a few failed attempts, ask a person.

An agent will happily report "Done!" while two tests still fail. A loop that trusts it ships broken work.

Defined by: Ralph loops (2025), built-in loop commands in Claude Code and Codex, and OpenClaw.

This is where the best teams are right now.

If you build today: write the stop conditions before you write the prompt.

5) Graph engineering (named July 2026): the bottleneck is composition

The name arrived six weeks after "loop engineering." On July 18, Peter Steinberger, the creator of OpenClaw, asked: "Are we still talking loops or did we shift to graphs yet?" The same day, Hamel Husain published "Loop Engineering Is Dead. Enter Graph Engineering." Two days later, Harrison Chase asked whether it's "basically just langgraph?"

Most of what's been written since agrees with him. A graph is nodes (an agent, a model call, a function, a tool or a person), edges that decide what runs next, and state that flows along the edges, all inside one runtime.

That's true, and it misses the real shift.

The early form: the agent writes the graph. Before the name existed, the harnesses had started doing it themselves. Claude Code's dynamic workflows (May 2026) have Claude write the orchestration as a script: fan out to tens or hundreds of subagents, have others try to refute their findings, and merge what survives. Codex has had subagents since March 2026, with an orchestration layer that spawns them, routes instructions and waits for every result.

Richard's original animation showing an agent generating a graph of parallel subagents and merging their results.

Nobody hand-drew those graphs. The agent engineered them for the task in front of it.

But every node is the same harness. Claude Code fans out to Claude Code, Codex to Codex. The graph stops at the harness boundary.

Why that boundary is the next wall:

  • One context window: a week-long job, with hundreds of sources and thousands of edits, outgrows any single window, even with compaction.
  • One harness: every step runs in the same harness, even when a different one would do that step better or cheaper.
  • One approver: a person can't review every step of a long run. They need a few checkpoints that matter.

Whole harnesses as nodes. This is already happening. A healthcare team we work with runs one long-horizon workflow to scrape and curate regulation data. Codex scrapes and normalizes the sources. Claude Code curates them and maps each rule to the clauses and policies it affects. Hermes verifies every citation against the source text. A person approves the curated dataset before it's published.

Richard's original animation showing a multi-harness workflow: Codex, Claude Code, Hermes and human approval.

Each node is a full harness running its own loop, with its own tools, memory and stop conditions. Each edge is a handoff with a contract: what has to be handed over, and what has to be true, before the next node starts.

What a graph engineer designs:

→ Topology: which nodes exist, who hands work to whom, and where work fans out and comes back together.

→ Shared state: what every node can read and write, kept outside any single harness, and who wins when two nodes disagree.

→ Routing and cost: which harness and model run each node, on what budget, with what fallback.

→ Edge contracts: what each node must hand over, and which edges need a person.

What's hard only across harnesses:

  • Handoffs: each harness keeps its own session and memory, so context has to be serialized at every edge.
  • Shared state: no harness owns it, so it needs a store all of them can read and write.
  • Routing: picking a harness per node needs measurements, not vibes.
  • Cost: one job now spends across several vendors at once.

So, is it just LangGraph? No. LangGraph, CrewAI and AutoGen graph function calls inside one runtime. Graph engineering, as I mean it, graphs whole harnesses: each node is a complete agent with its own loop, and the nodes can come from different vendors.

Where harness engineering goes

Harnesses become node types. You stop standardizing on one harness and start picking one per step, the way you pick a cloud instance type. And the agent that writes the workflow picks the harness for each node, the same way dynamic workflows already pick what each subagent does.

That's why I think harnesses commoditize. The value moves to the graph that composes them.

The problem nobody has solved

Evaluation. We have benchmarks for models, and more and more for harnesses. Nothing tells you whether a graph topology is any good: whether six nodes beat three, which edge caused a wrong answer, or whether a cheaper harness on one node would have done just as well.

Whoever solves that owns the next era. More on this soon.

My bets for Q1 2027 (hold me to them)

  1. "Graph engineer" shows up as a job title, the way "prompt engineer" did in 2023.
  2. Picking a harness becomes a per-step runtime decision, like picking an instance type. Nobody "standardizes on" one harness.
  3. Most long-running production agent work runs as multi-harness graphs, not single-agent loops.

Prompt engineering was never the skill; it was the bottleneck of its moment. The same is true of every era since. Learn the current layer, but bet on the next bottleneck.

→Next

Run supported harnesses through one interface

Use HarnessRouter to execute agent tasks, inspect traces and compare supported harness and model configurations on your own work.