Long-running agent

Agentic AIArchitecture and orchestrationPublished By Simon Budziak

A long-running agent is an AI agent designed to continue a task across hours, days, interruptions, and process restarts. It stores progress outside the model context, resumes from checkpoints, waits without consuming resources, and preserves enough evidence for a person to understand what happened.

OpenAI Agents SDK provides the primary reference used for this definition and its production boundaries.

How does long-running agent work in production?

Long jobs cannot depend on one model context staying alive. The runtime writes durable state, creates an agent checkpoint, and resumes a new agent session when work returns. Durability belongs in the runtime, not in the prompt.

When does long-running agent matter?

Use this pattern for research, approvals, migrations, or workflows that wait on people and systems. Agent recovery should replay only safe steps, while agent memory stores reusable knowledge rather than execution state. A long clock does not justify an unbounded task.

Frequently asked questions

What is long-running agent used for?

Use this pattern for research, approvals, migrations, or workflows that wait on people and systems. Agent recovery should replay only safe steps, while agent memory stores reusable knowledge rather than execution state.

Does a long-running agent need one continuous model session?

No. A reliable design persists state and can resume in a new process or model session.

Summarize this page with

See this working in a system we built