An individual project: a digital wardrobe you fill by photographing your real clothes. Each photo is cut out and recognised in the browser, redrawn as a cartoon garment that fits a customisable 2D avatar, and saved to your closet so you can mix outfits in a pixel-art room.
The problem
It's hard to remember everything you own, so the same few outfits get worn while other clothes sit unused. drezzit makes the closet browsable and suggests outfits, without a paid API: background removal and recognition both run on the device.
What it does
Add clothes from one or several photos; the background is removed in the browser.
An on-device CLIP model guesses each garment's type, pattern and material, and every guess can be changed.
Garments are redrawn as cartoons in the avatar's style, or kept with the photo's own texture.
Layered try-on for tops, dresses, bottoms, outerwear and shoes, with separate slots for hats, glasses, scarves and bags.
"Surprise me" outfits scored on colour harmony, the weather, season tags and how recently each item was worn.
An outfit diary with a calendar, plus most-worn and long-unworn items.
Saved looks, sharing a look as an image, and avatar and room customisation.
Google sign-in, a demo closet that works with no backend, export of everything as a ZIP, and account deletion.
Installable as an app, with offline startup and a cached cut-out model.
Engineering decisions
Photos never leave the device for processing
Background removal and garment recognition run in Web Workers in the browser. Only the cut-out, its cartoon and a thumbnail are uploaded, to a private storage bucket that Row Level Security limits to its owner.
Half of the recognition model is pre-computed
The text embeddings for every garment label are generated once at build time and shipped as JSON, so the browser downloads only CLIP's image model.
Headers that make cut-outs faster
Cross-origin isolation headers turn on multi-threaded background removal, which the README measures at about 2.5 times faster, and the service worker is never cached so updates roll out.