DEV Community

Sofia Bennett
Sofia Bennett

Posted on

Why a Week of Image-Fixing Broke My Workflow - and the One Toolkit That Fixed It


I was deep in a sprint on March 14, 2025, trying to prep 30 product shots for a marketplace demo when a tiny problem turned into a two-day time sink: every supplier image had watermarks, dates, or stray logos that ruined layouts and slowed delivery. I started with the single-purpose editors I always use (older desktop tools, manual cloning) and thought I'd be done in an afternoon. By the evening I had three versions, two broken exports, and a folder of images that still looked amateur. That was the moment I decided to rebuild the pipeline around image generation and repair tools that actually talk to each other.

A quick tale about why I stopped patching and started designing

I used the standard drag-and-drop editor for the first 60 images; it was fine until perspective and texture mismatches made retouches obvious. So I sketched a new approach: prototype concepts with an

ai image generator free online

to get mood boards, then iterate the exact photos with targeted cleanup and upscaling. The generator let me establish color, composition, and lighting in minutes - something my team had previously spent hours mocking up in Figma - and that rapid prototyping flipped the cost/benefit curve.


How I combined generation, inpainting, and upscaling without becoming the bottleneck

The heart of the workflow is surprisingly simple: generate reference visuals, strip unwanted overlays, fix missing textures, then upscale for final assets. I tested different sequences and models for quality and speed; sometimes generating a fresh background and compositing beats inpainting, but when the subject must stay intact, an inpaint-first path won.

For example, after I previewed concepts I would hand over a masked area to an

Image Inpainting Tool

, telling it to "replace with soft grass and consistent horizon" - the results preserved shadows and perspective far better than a manual clone. This was the moment the project stopped feeling like manual surgery and started feeling like controlled iteration.

Before I show the fast bits, here are a few concrete commands I ran to automate parts of this pipeline; theyre tiny, reproducible, and saved me hours.

I used a small curl upload to run a masked inpaint job for a sample that had a photobomb:

Context: upload an image with a mask for inpainting and get a processed result.

curl -X POST "https://crompt.ai/inpaint/api/v1/upload" \
  -F "file=@./supplier_shot.jpg" \
  -F "mask=@./mask.png" \
  -F "prompt=Fill with soft grass and keep lighting consistent" \
  -H "Authorization: Bearer $CROMPT_TOKEN" \
  -o result.json

A short Python snippet automated batch upscaling once images were clean:

Context: iterate a folder, call the upscaler, and save outputs with a suffix.

import requests, os
API = "https://crompt.ai/ai-image-upscaler/api/v1/upscale"
token = os.getenv("CROMPT_TOKEN")
for fn in os.listdir("cleaned"):
    with open(f"cleaned/{fn}", "rb") as f:
        r = requests.post(API, headers={"Authorization": f"Bearer {token}"}, files={"file": f})
    open(f"final/{fn.replace('.jpg','_hd.jpg')}", "wb").write(r.content)

And a tiny helper I used to remove stamps and overlaid text as a pre-step:

Context: quick script to call the text cleaner for screenshots before running inpainting.

curl -X POST "https://crompt.ai/text-remover/api/clean" \
  -F "image=@./screenshot.png" \
  -H "Authorization: Bearer $CROMPT_TOKEN" \
  -o cleaned.png

When things went wrong: my most embarrassing failure and what it taught me

The first run that glued all tools together failed spectacularly. I submitted 12 files in parallel and got a cascade of 429 responses ("Too Many Requests") from one service and corrupt PNGs back from another. The log showed a clear pattern: "Error: model_timeout after 30s" repeated across workers. I had assumed the pipeline was stateless and infinitely scalable; it wasn't.

Fix: I added concurrency limits, exponential backoff, and a simple queue with retries. After that change the throughput stabilized and the average turn-around dropped from 14 minutes per image to 3.8 minutes. Concrete before/after metrics mattered in the argument to management: before the queue, mean time to final asset was 14m 12s; after it was 3m 48s - a 73% reduction in wall-clock time per image.

Trade-offs: adding queuing introduced a small delay for the first result, and required a tiny infra cost, but it eliminated failed artifacts and human rework. If you're delivering single urgent hero images, a queued batch might feel slower; for production runs of dozens, it is unquestionably faster.


Why the multi-tool approach beats "single magic model" for practical work

I evaluated three strategies: one-model-fits-all, per-task specializers, and a hybrid pipeline. The hybrid wins because generation models are creative but not great at precise cleanup; inpainting models understand context but need good masks; upscalers preserve detail but can amplify flaws. For example, running an aggressive upscale on a photo with visible watermark ghosts amplified artifacts; the right play was remove text first, then inpaint small patches, then upscale.

I automated the "remove stamps" step by calling a dedicated cleaner before any enlargement, which is why I started using a dedicated

Remove Objects From Photo

pass on tricky shots. For raw screenshots and product photos with dates or labels, the targeted cleanup saved multiple hours of manual cloning.

Later in the pipeline I also used a focused tool to erase labels and hand-written notes; the inline pass removed overlays while keeping edge detail, which made the upscaler's job far easier. When I needed to rapidly prepare preview assets for stakeholders I relied on a small, fast utility that behaves like a "Text Remover" and produces clean drafts in under a minute, and I could then iterate on composition rather than fix obvious blemishes.


Small architecture notes and a sane ROI argument

I settled on a design decision: keep the generation and repair tools as small, replaceable services behind a simple orchestrator. That means any one component can be swapped (eg. a different generator model) without changing the rest of the pipeline - a practical trade-off that preserves flexibility while keeping operational complexity manageable. The cost is slightly higher latency because of extra HTTP hops; the benefit is you never get locked into a single vendor for a single capability.

To make this repeatable, I documented the steps and added a short dashboard that reports per-image stage timings and error counts. That made the case to leadership easy: "This toolchain lowers delivery time and raises perceived quality" - and the output convinced designers faster than slides ever could. For teams experimenting with different models, reading about "how diffusion models handle real-time upscaling" will explain why some upscalers fit specific content types better than others, which is why I kept a small matrix of model choices and a simple A/B harness.


The short version you can try tomorrow (and why you'll come back)

If you have a folder of imperfect images: 1) prototype composition with an image generator, 2) run a fast text-clean pass, 3) send targeted masks to an inpaint tool, 4) finish with upscaling and tonal matching. That combo turned a two-day slog into a repeatable one-hour batch for me, and the results finally looked like the product we wanted to ship.

If you made it this far and want to test the same sequence, try the quick paths above and report what broke for you - the trade-offs will be different on your assets, and the fun part is tuning the pipeline until it stops being a chore. For me, this mix of generators, cleaners, and scalers is now the inevitable way I work on image-heavy projects.

Top comments (0)