I Design AI Workflows for Cheap Rejection
I do not judge an AI workflow only by how often it produces an acceptable result. I judge it by how much work it creates when the result is wrong.
A good path gets most of the attention: better prompts, faster models, cleaner plans, higher pass rates. The rejected path is usually an afterthought. It ends with a red badge, a vague comment, or another conversation that starts from zero.
That is expensive. In real engineering, rejection is not an exception. It is one of the normal ways a proposal becomes information.
So I design AI workflows for cheap rejection.
A rejection can destroy or preserve work
Imagine an agent changes twelve files and the reviewer finds one violated boundary. A weak workflow returns the entire patch with “not acceptable.” The next run must rediscover the task, infer the objection, regenerate the patch, and repeat checks that may already have been useful.
A stronger workflow rejects one claim precisely:
REJECTED
reason: public API changed outside approved scope
failed_check: api-surface-diff
retained: tests, dependency scan, unchanged-file proof
next_action: restore public signature and rerun contract tests
The patch still cannot be accepted. But the work did not collapse into zero. The rejection identifies the failed boundary, preserves valid evidence, and defines the smallest next move.
This is the difference between a verdict and a transition. A verdict labels the past. A transition also shapes what may happen next.
“Try again” is not a recovery strategy
Chat interfaces make repetition look cheap. The model can generate another answer immediately, so “try again” feels like progress.
But a new answer often changes more than the rejected part. It may rewrite working code, alter assumptions, discard useful evidence, or introduce a different failure. Without a retained failure identity, the next attempt is merely another sample.
I want a rejection to carry four things:
| Field | Purpose |
|---|---|
| failed condition | names exactly what prevented acceptance |
| evidence reference | preserves the observation that proved it |
| retained work | states which artifacts remain valid |
| bounded next action | limits what the next run is allowed to change |
This is intentionally smaller than a full incident report. Most rejected proposals are not incidents. They are routine control flow. The artifact should be cheap enough to produce every time and precise enough to prevent a conversational reset.
The closest concept in HTTP is not “error” in the abstract but a response with semantics: the status tells the client whether the request was malformed, unauthorized, conflicting with current state, or temporarily impossible. Different failures authorize different next actions. Agent workflows need the same discipline.
Rejection must be cheaper than reconstruction
There is a simple economic test: if recording the rejection costs more than reconstructing the failed run, the mechanism is too heavy. If reconstructing the run costs more, the rejection is too vague.
I therefore keep the rejection packet close to the acceptance contract. The same conditions that define success should define why a candidate failed. If a task says that only src/ may change, the workflow should not need a human essay to explain that a generated edit under infra/ is out of scope. The failed condition already has an identity.
{
"candidate": "patch-42",
"outcome": "rejected",
"failed_condition": "scope.allowed_paths",
"observed": ["infra/deploy.yml"],
"retained_checks": ["unit-tests@8f31", "dependency-audit@8f31"],
"next_scope": ["src/**"]
}
This does not guarantee that the retained checks remain valid forever. Their identity must include the artifact revision and relevant environment. If the next attempt changes dependencies, the dependency audit is stale. Cheap rejection is not permission to reuse evidence blindly.
It is permission to avoid throwing evidence away blindly.
The next attempt should be smaller
A useful rejection reduces uncertainty. The next run should therefore be narrower than the previous one.
If an agent violated file scope, freeze the accepted files and reopen only the offending area. If a factual claim lacked a source, preserve the structure and reopen the claim. If a migration failed one compatibility probe, do not regenerate the whole migration plan; bind the next attempt to that incompatibility and its affected consumers.
This is where I see a practical link to IOSM CLI as an engineering runtime. A controlled cycle is valuable not because every hypothesis succeeds, but because a failed check can become a bounded input to the next cycle. Checkpoints, artifacts, gates, and event history make that narrowing possible.
The same idea appears in the way I measure AI work by time to accept. A result sitting in an ambiguous review queue is unfinished. Precise rejection is one legitimate finish state—and often the fastest route to a later acceptance.
Cheap rejection changes what I am willing to automate
I am more comfortable delegating a task when a wrong proposal is easy to stop, explain, and revise without hidden side effects.
That does not mean I lower the quality bar. It means I can explore a larger proposal space without converting every mistake into cleanup work. The model may be uncertain above the boundary. Below it, the workflow must know how to refuse.
This also changes prompt design. Instead of asking only for “the best solution,” I ask for output that can fail locally: named assumptions, scoped edits, explicit acceptance conditions, and evidence tied to the candidate. Local failure is easier to reject than a polished answer whose claims and actions have been fused into one narrative.
I do not want a model to argue its way past a failed check. I want the system to record the failure, retain what is still valid, and expose the smallest honest continuation.
Rejection has limits
Not every effect can be cheaply rejected. Once an email is sent, money is transferred, or public state changes, the system may need reconciliation or compensation rather than rejection. That is why proposal and effect boundaries matter. The cheap-rejection pattern belongs before irreversible commitment.
Nor should every rejected artifact be retained. A candidate built on a false premise may contaminate all downstream evidence. In that case the correct retained set is empty. The value lies in making that decision explicit rather than assuming that all work is reusable—or that none of it is.
Finally, reason codes can become bureaucratic noise. I keep them tied to executable or reviewable conditions. A taxonomy that does not change routing, scope, evidence reuse, or the next action is decoration.
Failure should leave the system smarter
I expect probabilistic systems to produce rejected candidates. Trying to eliminate that fact usually hides rejection inside human review, cleanup, and repeated prompting.
I prefer to engineer the rejected path directly.
A strong AI workflow does not merely succeed gracefully. It fails with a precise address, preserves the evidence that still holds, and makes the next attempt smaller. That is not pessimism. It is how uncertain work becomes cumulative engineering instead of repeated improvisation.