How the Flow Error Analyzer Agent works
Flow Error Analyzer is a built-in Ploy agent that watches every failed workflow execution, diagnoses the failure, retries transient ones once, proposes one safe fix, and publishes a weekly failure rollup. Its tagline sums it up: "Watches every flow failure, diagnoses it, and fixes what it safely can." It is enabled by default, so you do not need to turn it on. It is not a playbook or a generated flow: it is one of the built-in agents described in What are built-in agents?.
What wakes it
The agent wakes in two situations: when a flow execution fails, and once a week on a schedule. Every failed flow execution wakes it through the Flow execution failed trigger, and a weekly run at 09:00 UTC produces a rollup of recent failures.
Two situations never wake it: a step configured to Carry on if it fails does not fail the overall run, so the agent sees nothing to investigate, and failures in the Flow execution failed trigger itself stay outside its view.
What it does
Each wake, the agent works through four duties:
Triage it determines what failed and whether the failure is new, recurring, or part of a burst.
Diagnose it identifies the failed step and the actual cause.
Act it retries established transient failures and proposes one evidence-based structural fix.
Report it notifies people, annotates the execution, and publishes the weekly rollup.
Failures are grouped into signatures by flow, failed step, and error text. A known signature stops repeat diagnosis and repeat notifications, and the first suppressed occurrence gets a single annotation. The agent diagnoses up to 25 new failure signatures per day.
Safety rails on changes
The agent never changes a flow on its own. Retries and flow edits are confirmation-gated: you approve each one, so nothing happens silently.
Retries follow strict rules. Only failed action steps can be retried; triggers and controls cannot. A transient failure is retried once and rechecked roughly 10 minutes later, and the same failure signature is not retried twice within roughly 24 hours.
Fix proposals are equally limited. The agent proposes at most one minimal flow change per failure signature, and only when the broken value and the replacement are both proven. The proposal needs your approval, and it happens once per signature.
What you see
The agent leaves a record for every piece of work it does:
A task for each new failure signature.
Notes and annotations on the flow execution, marked investigated, retried, or diagnosed.
A notification to the flow creator or an admin when action is needed.
A weekly failure rollup.
Agent activity history.
These records are tasks, annotations, and notifications, not Luna artifacts. For how artifacts work, see Artifacts.
How long it runs
Flow Error Analyzer is standing work with no finish line: it keeps watching failed flows until you disable or archive it. For the built-in agents overview, see What are built-in agents?. To see where flows come from in the first place, read Generate automation flows with Luna AI or What are Luna playbooks?.