Skip to content
Goat head chess knight pieceA theme-aware monochrome engraving-style illustration of a chess knight piece with a goat head.Sam Ananias Cases
Back to field ledger
Lab entryEXP.43active

ID Photo Studio

Can a print-ready ID photo be produced entirely in the browser — with the portrait never uploaded anywhere?

  • React 19 Island
  • Canvas
  • ONNX/WASM
  • Cloudflare Workers
On this page

What this entry set out to test

  1. 01Keep the full pipeline client-side so no image bytes ever leave the browser.
  2. 02Serve canonical export presets and metadata-only telemetry from a thin Worker.
  3. 03Reserve a paid-fallback seam without shipping image upload.

Overview

Free ID-photo tool: upload a portrait, remove the background locally in the browser, crop to Philippine ID presets (2x2 at 600x600px, 1x1 at 300x300px), pick a background, and download a print-ready file.

Privacy Model

Heavy ML stays on-device via @imgly/background-removal-js (AGPL-3.0). The Workers backend serves canonical preset config, records metadata-only usage telemetry, and reserves a 501 stub for a future paid fallback — it never receives image bytes.

Backend Contract

  • GET /api/crop/config — canonical presets, backgrounds, export caps.
  • POST /api/crop/usage — metadata-only { event, preset, ms } telemetry.
  • POST /api/crop/remove — 501 with fallback: client until a paid fallback is enabled.

The live tool or source backing this entry.

End of entry · return to the ledger