Foundation 04 · Task state and handoffs

Make waiting
visible.

Long-running work needs more than a start and an end. A task state, progress update, artifact, cancellation rule, or human handoff should tell the next participant what is happening, what may happen next, and who must decide.

Learning boundary. A task model makes state and handoff visible; it does not make a human review happen, guarantee liveness, verify an output, or authorize an external effect. The application must connect protocol state to an actual policy and operating process.

Learning objective

Design an asynchronous path that can stop without becoming ambiguous.

By the end of this lesson, you should be able to name task states, progress events, artifacts, cancellation conditions, escalation owners, and return-to-work rules for a workflow that may outlive its initiating request.

01 · State

What is true now?

Choose a small state vocabulary that distinguishes submitted, working, input-required, failed, canceled, rejected, and completed where the workflow needs it.

02 · Transition

What changes the state?

Record the event, actor, condition, and evidence that permits a transition. A status label is not a substitute for the event that produced it.

03 · Handoff

Who must decide next?

Make input-required and escalation states name the responsible role, required context, deadline, and safe default. Do not label a queue as human review unless a human owns it.

04 · Resume

How does work continue?

Keep the task and context references stable, specify cancellation and retry behavior, and record what happens to partial artifacts when work stops.

Practice lab

Build a safe pause.

A remote agent receives a research task, discovers that the requested action would cross a spending threshold, and emits an input-required update. The requester is offline for six hours while the task remains open.

  1. Define the task state, the reason for the pause, and the evidence attached to it.
  2. Name the role that may approve, reject, or revise the request.
  3. Set a cancellation or expiry rule that does not silently authorize the effect.
  4. Describe how the workflow resumes and how a reviewer distinguishes the old context from new instructions.

Source shelf

Study task lifecycles and human-in-the-loop patterns.

  1. Agent2Agent Protocol specificationStudy task lifecycles, status updates, artifacts, cancellation, push notifications, and input-required patterns for long-running interactions.
  2. Model Context Protocol specificationCompare progress, cancellation, elicitation, and sampling controls. These features expose interaction points; they do not replace application policy or consent.