Workflow ideas
What changes when an AI workflow goes from demo to production?
A successful run proves the happy path. Reliable automation also needs durable state, bounded retries and a clear owner for exceptions.
By Automate HQ · Updated · 3 min read
At a glance
The main change is responsibility for failure. A demo can be rerun by its builder. A production workflow must explain what happened, avoid repeating completed actions and give an owner a safe recovery path.
- 01Event ID
- 02Validate
- 03Deliver
- 04Reconcile
A timeout is an unknown outcome
Consider a lead workflow that appends a Google Sheets row and then posts to Slack. If the Slack call fails, replaying the whole execution creates a second row. If the Sheets call times out, the row might already exist. A missing response is not evidence that nothing happened.
Give every business event a stable identifier. Keep a durable record of receipt, validation, sheet delivery and notification delivery. Recovery can then resume the incomplete step. In a concurrent system, enforce uniqueness in storage; checking a sheet and then appending leaves a race between those two operations.
Retry operations according to their effects
A read is usually safer to retry than a write. A model request may be retried, but another attempt can incur a charge and return a different suggestion. An append can duplicate a record. A notification can reach someone twice. One global retry policy hides these differences.
Use bounded retries with backoff and jitter for transient failures. Respect provider rate limits, stop retrying invalid credentials and record attempt counts. For writes, use provider idempotency keys where supported or a durable delivery record with a reconciliation path. The free lead template avoids automatic write retries and explains the manual recovery step.
Separate model judgement from business authority
A model can suggest that a lead is urgent. It should not quietly decide that the lead qualifies for a discount, a contractual promise or access to an internal system. Encode business permissions outside the prompt. The prompt is not an authorization boundary.
Keep a labelled evaluation set, including ambiguous messages, missing fields, multiple languages and adversarial instructions embedded in the input. Compare model suggestions to reviewed examples when changing the model or prompt. Measure wrong routing and review workload, not just the number of successful API responses.
Make the workflow operable by someone else
Record structured status, latency, attempt count and an event ID without copying entire private documents into every log. Define who receives alerts, what they inspect and how they resume a partial run. A generic error email is less useful than a message that identifies the failed delivery step and a safe recovery action.
Start with the downloadable lead workflow and a test spreadsheet. Deliberately break the Slack credential after a successful sheet append. Observe the partial result, then write down a recovery procedure. That exercise exposes the engineering work more clearly than another happy-path demo.
Try the workflow
Turn a website enquiry into a scored lead, a spreadsheet row and a Slack notification. Keep the final decision with your team.
Download the free AI Lead Qualification template →