Prompt Engineering vs Loop Engineering vs Graph Engineering: What Changes at Each Layer
Three phrases now compete for a similar line in AI engineering job descriptions. Prompt engineering is the established one. Loop engineering entered the AI vocabulary in late 2025 and dominated developer dialogue by means of June 2026. Graph engineering adopted roughly six weeks later.
They get used interchangeably. Should they be?
The three are usually not competing methods. They are three totally different models of management, stacked. A immediate controls one mannequin response. A loop controls one agent’s conduct cycle. A graph controls the group of many brokers. Each layer preserves the layer beneath it. A immediate doesn’t disappear as soon as a loop is constructed round it. it stops being the factor typed by hand.
This article separates the three: what will get designed at every layer, what the printed declare says about when the upper layers pay for themselves, and the place the skepticism is warranted.
Interactive explainer · 01
One job, three layers — watch what modifications
The three phrases are usually not competing methods. They are three totally different models of management. Here is identical job dealt with at every layer, step-by-step. Orange dots mark the moments a human is required.
Layer 1
Prompt engineering
You management one mannequin response. You are the loop.
Layer 2
Loop engineering
You management one agent’s cycle. The loop does the prompting.
Layer 3
Graph engineering
You management what number of brokers are organised.
What truly differs
| Prompt | Loop | Graph | |
|---|---|---|---|
| Unit of management | One mannequin response | One agent’s behaviour cycle | An organisation of brokers |
| What you write | Instructions, examples, output format | Trigger, instruments, cease situation, retry finances | Nodes, edges, shared state, failure routes |
| Who says “once more?” | A human, each flip | A verifier the loop calls itself | A routing rule written upfront |
| Where it breaks | Ambiguous or overstuffed instruction | It can not inform completed from caught | Context by no means crossed an edge you forgot to attract |
| Enough when | One shot, an individual reads the outcome | Repetitive, machine-checkable, one area | Cross-domain work with parallel branches |
Built by Marktechpost
The stack, so as
Each step within the development was named in observe earlier than it appeared in vendor documentation.
- Prompt engineering covers writing and structuring the instruction for a single name. Anthropic’s guidance is to separate a system immediate into labeled sections — background data, directions, device steerage, output description — delineated with XML tags or Markdown headers. The suggestion is to provide the minimal set of data that absolutely specifies the anticipated conduct. Minimal doesn’t imply quick.
- Context engineering got here subsequent. Anthropic describes it because the pure development of immediate engineering. The query strikes from discovering the best phrases to deciding what configuration of tokens belongs within the window at all. Context is a finite useful resource, and the engineering downside is optimizing the utility of these tokens towards mannequin constraints.
- Harness engineering covers the setting a single agent runs inside: information, instruments, reminiscence, suggestions.
- Loop engineering sits one ground above the harness. A June 2026 arXiv paper on agentic AI in constructing engineering, Buildrix, units out the identical four-step development explicitly — immediate, then context, then harness, then loop — with the ultimate layer defining how a system repeatedly observes, acts, verifies and recovers.
- Graph engineering is the latest label and the least settled. One enterprise writeup notes that the time period’s provenance is unresolved and that it collides with an older knowledge-graph utilization of the identical phrase. The underlying observe, graph-based orchestration, has a documented lineage in multi-agent techniques analysis.
Layer 1: Prompt Engineering
The defining assumption is {that a} human is current at each iteration. A immediate is written, the mannequin responds, the output is judged, the immediate is revised.
That assumption is what breaks. High quantity. Multi-step duties. No human out there to grade the output. Results that feed the following step robotically. Any one in all these, and the immediate alone stops being adequate.
Nothing concerning the immediate acquired worse. The surrounding situations modified.
Prompt engineering additionally doesn’t vanish inside the upper layers. Anthropic’s multi-agent research writeup stories that immediate engineering was the main lever for fixing coordination failures. Early variations spawned 50 subagents for easy queries, and the repair was prompting quite than topology.
Interactive explainer · 02 · Layer 1
What immediate engineering is
Prompt engineering is designing the textual content of a single name to a mannequin. One enter, one ahead cross, one output — and a human who reads the outcome and decides whether or not to run it once more. That final half is the belief all the pieces above this layer exists to take away.
Swipe the diagram sideways →
The cycle exists right here too — however you’re the one closing it, each single flip.
Anatomy of a immediate
Tap a piece. Anthropic’s steerage is to delineate components with XML tags or Markdown headers quite than writing one undifferentiated block.
What this part does
Background data
The assumption that breaks
Prompt engineering assumes a human is current at each iteration. Tap a situation to see what occurs when that stops being true.
Built by Marktechpost
Layer 2: loop engineering
The framing is {that a} coding agent is a brute-force device for locating options. The craft is designing the aim, the instruments and the loop and never solely the immediate.
The time period reached mainstream developer dialogue in June 2026, after a broadly shared put up argued that engineers ought to cease prompting coding brokers and begin designing the loops that immediate them. The Claude Code workforce at Anthropic described the identical shift on stage that week.
The most detailed public breakdown identifies 5 primitives, plus a sixth factor that holds them collectively:
- Automations: a schedule or occasion that performs discovery and triage with out supervision
- Worktrees: isolation so parallel brokers can not edit the identical information
- Skills: venture information written down as soon as in a
SKILL.md, quite than re-explained each session - Plugins and connectors: MCP-based entry to the problem tracker, database or staging API
- Sub-agents: a maker/checker break up, for the reason that mannequin that wrote the code grades it too generously
- State: a markdown file or board outdoors the dialog, as a result of the mannequin forgets between runs
Two in-session options are crucial. /loop re-runs on a cadence. /aim runs till a written situation is definitely true, with a separate small mannequin checking after every flip — so the agent that wrote the code isn’t the agent grading it. Both Claude Code and the Codex app ship equivalents.
The cycle isn’t the onerous half. The cease situation is. A loop that can’t mechanically distinguish completed from caught doesn’t fail loudly. It retains spending tokens.
Interactive explainer · 03 · Layer 2
What loop engineering is
Loop engineering is designing the system that prompts the agent, as a substitute of prompting it your self. The immediate doesn’t disappear — it turns into a element inside a cycle that decides when to fireplace, what counts as passing, and when to cease making an attempt. The talent was named in September 2025 and have become the dominant developer subject in June 2026.
The cycle
Four phases and a reminiscence. Press run to look at one full, then power a failure to see why the guardrails exist.
Run log
Everything under occurs with no person watching. That is the entire level, and the entire danger.
A loop wants a stopping rule it could actually consider with out you. Without one it doesn’t fail loudly — it simply retains spending.
What you truly construct
A working loop wants 5 primitives plus a spot to recollect issues. Both Claude Code and the Codex app now ship all six. Tap one.
Built by Marktechpost
