If you've ever needed an agent to do something that takes three days, not three seconds, you know the workaround: cram it into a system prompt and hope. That's over. As of noon UK time today, Workflows is live in production, and Lua CLI v3.31.0 ships the tools to build with it.
A workflow is a durable, multi-step process an agent can run for minutes, hours or days, with a person in the loop exactly where you want one. It survives restarts and deploys. It waits for a human without burning compute while it waits.
What you can build now
Static workflows, written in TypeScript: code steps, nested workflows, sleeps, signals, branches and loops, all durable across restarts and deploys.
Dynamic workflows: an agent composes and runs a workflow from a goal at runtime, instead of you writing every step by hand.
Human-in-the-loop approval gates, with paste-anywhere links, timeouts and escalation. A run can wait three days for a yes without holding any compute the whole time.
Templates: install a workflow onto an agent straight from the catalog, with a bound recipient.
Runs and events: every run keeps a ledger you can replay. The desktop app's Runs page streams live step logs, tool inputs and outputs, and the agent's own notes, and keeps all of it as an audit trail after the run ends.
Lua's own Ticket Pilot, the Linear-to-PR coding agent, runs end to end on Workflows now: scout to delivery, no separate glue code.
How it works, briefly
You define a workflow as a chain of steps in code: createStep for a code step, .agentStep for a turn the agent takes, .approval for a human gate, then .commit(). Run it locally with lua test workflow, push a version with lua push workflow, and deploy it with lua workflows deploy. Starting a run returns immediately with a run id, and --follow streams the events as they happen, including the moment it suspends and waits on someone to approve.
A hard drive and a CPU for the agent
Most steps run in the agent's regular sandbox, capped at 10 minutes. That's fine for a lookup or an API call. It's not enough for a coding task, a full test suite, or anything that needs a real checkout of a repository.
For that, a step can declare tier: 'job'. It runs in its own container instead: a mounted git workspace, checkpoints every few hours, and, for an agent step, a full coding session using Claude Code. Give it workspace: { mount: 'rw' } and the workflow clones the repo in; the agent can then read, write and edit files and run shell commands against it, same as a developer would on their own machine. Sizes range from small to large in CPU and memory, and a code step can run up to 4 hours, an agent step up to 24, checkpointing as it goes.
Credentials never touch the container itself. A GitHub connection mints a short-lived, repo-scoped token that sits with a sidecar next to the container, and every push is admitted only to that run's own branch. It's how Ticket Pilot gets from a Linear ticket to an open PR without anyone handing an agent a standing key to the whole org.
Multiple coding turns can even work the same checkout in parallel, each in its own worktree and branch, with a merge step folding them back together, for example splitting implementation, tests and docs across three arms at once.
Under the hood
A durable engine with its own worker fleet and a separate sandbox lane, idempotent billing per operation, a sweeper that heartbeats to Better Stack, and a four-layer gate (environment, agent feature, org policy, agent settings) so nothing runs for an org that hasn't opted in.
Get started
Docs: docs.heylua.ai/workflows/quick-start, covering authoring, runs and events, and the full CLI reference. The job tier page has the full detail on containers, workspaces and credentials.
Install lua-cli@3.31.0 for the new lua workflows command family: start, follow, status with step previews, signal, approve, pause, resume, cancel and more.
Go build something that runs while you sleep.