An AI agent that can send messages, move money or change records cannot run safely on its own judgement alone. This article explains how AI agents handle human-in-the-loop interventions: the pause before a consequential action, the decision a person must make, and how the run resumes afterwards.
For in-run interventions, a human-in-the-loop intervention is a designed break in an agent’s work, built in before the agent ever runs. A person must decide, correct or take over before the agent may continue that run, or the run may end at a handoff instead. Post-hoc review is different: it examines a completed run afterwards and feeds future runs, rather than pausing one. It protects no one if the person cannot judge the question, or the checkpoint cannot stop the action.
What a human-in-the-loop intervention is
For in-run interventions, a human-in-the-loop intervention is a designed pause in an agent run where a person decides, corrects or takes over before the agent proceeds. The agent reaches a point it may not pass alone, stops, and hands a decision to a person. Post-hoc review, described below, is different: it examines a completed run rather than pausing one.
The forms follow from what the person may do. In an approval, the person says yes or no to one action, such as cancelling an order. In review and edit, the person changes the proposal — amount, recipient, wording or scope — and the agent proceeds with the edited version. In escalation or handoff, the agent stops and hands the whole task to a person, with its work so far attached, and the agent run may end there rather than resume. In interrupt and redirect, a person steps in mid-run to change the goal or plan. In post-hoc review — a retrospective check, not a pause-and-resume intervention — the run completes first, and the review feeds future runs.
An intervention differs from nearby controls. Monitoring watches without the power to stop anything. Auditing examines events after they happen. A guardrail tripwire is an automatic check: in the OpenAI Agents SDK, guardrails validate input, output or tool behaviour automatically, while human review pauses the run so a person or policy can approve or reject a sensitive action. The guardrail decides by rule; the intervention decides by human judgement.
Where human-in-the-loop interventions sit in the agent loop
An agent works in a loop: perceive, decide, act through a tool, observe the result, and decide again. Interventions sit at checkpoints in that loop. The most important checkpoint is before a consequential tool call — before the agent sends, pays, deletes or changes something in the outside world. Others sit during planning, where a person reviews a proposed plan, and after outputs, where a person reviews a draft before it reaches anyone else.
Placement decides what a checkpoint can prevent. A checkpoint before a tool call can stop the action itself. One during planning can stop a bad approach before it generates actions. One after an output can stop a message going out, but cannot undo work already done.
A pause works only if it preserves state: the run, its plan, the proposed tool call’s arguments and the conversation context must survive while the person decides, whether that takes seconds or days. In LangGraph, the checkpointer writes the exact graph state when an interrupt triggers, and the thread identifier tells it which saved state to load on resume. In the OpenAI Agents SDK, a paused run can be serialised as a RunState, restored later — even in a different process — and resumed as the same run, not a new turn.
How an agent handles a human-in-the-loop intervention, step by step

Every in-run intervention follows four steps: a trigger fires; the agent pauses and packages the decision; the human decides and the decision is recorded; the agent resumes, branches or hands over, acting only on the decided outcome, with the intervention logged.
The trigger can be a risk rule, such as any payment always needing approval. It can depend on the specific call: in the OpenAI Agents SDK, a tool may declare that it needs approval always, or through a function deciding per call from the parsed arguments — for example, requiring review when an email subject contains the word refund. Or the agent itself may ask when uncertain, when evidence is thin, or when instructions conflict. A trigger firing on every action risks a queue of interruptions that people approve with less and less attention.
Next, the agent pauses and packages the decision: the proposed action in plain terms, its arguments, the evidence behind it, and what happens if it goes ahead. In LangGraph, the interrupt call carries a payload of any JSON-serialisable value, surfaced to the caller. The JSON below shows the shape of such a payload for a payment, as an illustration, not a claim about a real transaction:
{
"action": "send_payment",
"amount": 480.0,
"recipient": "Acme Supplies",
"evidence": "invoice INV-1042, due today"
}Then the human decides. In LangGraph, resuming with a Command carrying the resume value makes that value the return value of the interrupt call, so the node continues with the human’s input. In the OpenAI Agents SDK, each pending interruption is approved or rejected on the RunState, and a rejection can carry a custom message back to the model, so the agent learns why the action was refused.
Finally, the run resumes — except where the outcome is a handoff, in which case the agent run may end instead, with the task now in the person’s hands. An approved call executes with the approved arguments; an edited proposal executes in its edited form; a rejected call must be handled — another approach, more information, or a stop — not quietly retried. The log records what was proposed, who decided, what they decided, and what happened next. Without it, no one can review whether checkpoints work, or who authorised a consequential action.
Types of human-in-the-loop intervention patterns

An approval gate is the narrowest pattern: approve or reject one proposed tool call before it executes. The OpenAI Agents SDK implements it directly: a tool declares that it needs approval, and the run pauses with the pending approval in its interruptions.
Review and edit gives the person more power: change the arguments, wording or scope, and the agent proceeds with the edited version. LangGraph documents this as a distinct pattern, including editing part of the graph state before the run continues. It suits proposals that are nearly right — a draft with the wrong date, a payment with the wrong amount — where rejection would waste work already done.
Escalation and handoff is the broadest pattern: the agent stops and hands the whole task to a person, with its work attached, and the agent run may end at that handoff rather than resume. It suits tasks the agent cannot resolve, such as conflicting instructions or missing evidence. Interrupt and redirect sits between approval and handoff: a person changes the goal or plan mid-run. Post-hoc review is the loosest, and the exception to the pause-and-resume shape: the run completes, a person reviews it afterwards, and the outcome feeds future runs. It fits low-risk work, and is no substitute for a gate on a consequential action.
Choose by the decision, not the tool. If the question is whether one action should happen, use an approval gate. If it is what the action should be, use review and edit. If it is whether the task should continue at all, use escalation. Mixing them up is how interventions fail while appearing to be in place.
Designing human-in-the-loop interventions in practice
Start with risk-tiering: which actions need real-time approval, which need sampled or post-hoc review, and which can run automatically. OWASP guidance calls for decomposing high-impact operations into discrete, human-reviewable steps, and for explicit human approval for actions modifying security-relevant configuration, permissions or infrastructure state — classifying actions by reversibility so read-only inspection runs unattended while irreversible changes are gated. The tier, not the agent’s confidence, decides the checkpoint.
Next, the context package: the action in plain terms, its arguments, the evidence behind it, and the consequence if it goes ahead. Bare tool arguments may be insufficient for a given decision, and evidence helps a suitably equipped reviewer — one who understands the system’s limits and can interpret its output — assess the proposal; presenting evidence alone does not guarantee effective oversight.
Then the mechanics of waiting. Review may be synchronous, with the person waiting, or asynchronous, with the request queued and the run paused. Both frameworks examined here support long pauses: LangGraph interrupts wait indefinitely, with state in the checkpointer, and the OpenAI Agents SDK lets a paused RunState be serialised, stored and resumed later. Neither framework’s documented interrupt behaviour states a built-in timeout. The timeout, the default when nobody answers, and the escalation path must therefore be decided explicitly by the application. A run waiting forever is stuck; a run proceeding by default after a timeout has turned a gate into a delay.
A worked example: a support agent prepares a refund of 480.00 to Acme Supplies against invoice INV-1042. The refund tool declares that it needs approval, so the agent pauses and packages the decision. The reviewer sees the amount matches a different invoice, edits it, and approves the edited version. The run resumes, the payment executes once, and the log records proposal, edit, approver and outcome.
At tool level, the mechanism is a declaration that the tool needs approval; the framework handles the pause, the surfacing and the resumption, and the application supplies the reviewer, the package and the decision.
Limits of human-in-the-loop interventions and common mistakes
The first limit is the person. Repeated requests lead people to approve without reading — approval fatigue. Anthropic reported that Claude Code users approve 97% of permission prompts. In a controlled study of 1,053 paid testers, people caught a planted dangerous command only 13.6% of the time, falling from about 17% early in a session to about 5% after 50 or more prompts, while a classifier-based auto mode caught 89% of the same commands. These figures are Anthropic-reported results as summarised in secondary coverage of a vendor-run study in a test environment, where approving the planted command executed nothing harmful — not a universal measure of judgement, and the primary study was not consulted for this article.
The second limit is context. A reviewer shown too little cannot judge, and a run that resumes uncleanly after a long pause cannot act on a good decision. LangGraph warns that a resumed node restarts from the beginning, so code before the interrupt runs again, and that after a long interrupt the agent should re-read external state — price, inventory, policy — before a mutating side effect, because the pre-pause world may have changed.
The third limit is scope. Over-blocking drives users to work around the agent, granting blanket permissions or disabling checkpoints. Under-scoping leaves consequential actions unchecked while a few gates create false safety. A checkpoint reduces risk; it does not remove model error, prompt injection or permission mistakes, nor fix badly gathered evidence. The EU AI Act makes the same point for high-risk systems: oversight must be commensurate with risks, autonomy and context of use, and overseers must be enabled to understand the system’s limits, remain aware of automation bias — automatically relying or over-relying on AI output — interpret output correctly, disregard or override it, and intervene or interrupt the system. The Act covers high-risk systems, not every agent, but its test is useful anywhere: can the overseer challenge the system, or only click past it?
Finally, accountability can blur. When a human approves an action proposed on flawed evidence, who is responsible — the person who clicked, or the system that presented the evidence? A log of proposal, evidence shown, decision and outcome does not settle that, but without it the question cannot be asked properly. Decide before deployment who owns each checkpoint, and make the log identify that owner.
A practical human-in-the-loop checklist
List consequential actions first: every action that sends, pays, deletes, publishes or changes permissions, with the pattern it needs and how quickly a person must answer. An action omitted from the list may lack an intentionally designed checkpoint, and should be checked against the actual approval policy, since per-call approval rules and conditional triggers can also catch actions the inventory missed; that check, not the list alone, decides whether an action is gated.
For each checkpoint, define the trigger, the context package, the permitted responses and the timeout default. LangGraph documents indefinite waiting for an interrupted run, while the OpenAI Agents SDK documentation consulted states no built-in timeout or default action; either way, an application-level timeout and escalation policy must be built deliberately if a timeout default is wanted. Give the human edit power where an edit beats a binary choice, and log every decision and override.
Test pause-and-resume before relying on it: timeouts, long waits, stale external state, and a resume after the application itself has restarted. Then review the logs regularly, and loosen or tighten checkpoints only on evidence. Count how often each fires, how often reviewers edit or reject, and how long decisions take. The goal is not more checkpoints, but fewer, better-placed ones, where a person’s judgement can actually change the outcome.












