An AI image editor can pass a demo and still fail in production.

The happy-path image looks clean, the progress state feels fast, and the output is impressive at first glance. Then real users upload low-contrast photos, click the action twice, refresh during processing, or ask the model to remove an object that overlaps a hand.

The hard part is not generating one good result. The hard part is making the feature testable when outputs are nondeterministic.

I use a small QA harness built around fixed fixtures, explicit invariants, repeatable run metadata, and human-readable review sheets. It does not pretend that image quality can be reduced to one perfect score. It makes failures easier to reproduce and discuss.

1. Define the operation and its invariants