# MakeupMe: how it works

How it works
The two models, what our code does with them, what is measured, and what stays on your device.


## Finding the hair
MediaPipe Tasks Vision, Google's library for running vision models in the browser, under the Apache 2.0 licence, version 0.10.21, with its hair segmenter model (0.8 MB): for every pixel, how likely it is to be hair. The runtime is WebAssembly; on browsers that allow it the models run on the graphics processor, otherwise on the processor. Sources: the MediaPipe image segmenter page, the licence, and the files themselves at /vendor/ and /models/.


## Finding the lips
The same library's face landmarker model (3.8 MB) places 478 points on a face; twenty of them trace the outer edge of the lips and twenty the inner edge. Source: the MediaPipe face landmarker page; the file is at /models/face_landmarker.task.


## Changing the colour
Our own code, about 620 lines, in /js/makeupme.js. The picture is drawn to a canvas; the hair likelihoods become a soft mask, and a guided filter moves the mask's edge onto the edges in the picture itself. The light and shadow inside your hair are measured (its darkest, middle and lightest parts), and a copy of the picture is mapped through the chosen colour's own range, from a shadow tone through the colour to a highlight, so the strands and shine stay while the lightness moves to the colour's. Where a browser cannot apply that filter to a canvas, it keeps the earlier way: the colour's hue and saturation on your own lightness. The copy is cut to the mask and laid over the picture at the strength you set. Lips are the same, cut to the ring between the outer and inner lip edges, softened at the edge; light, grey pixels in the mouth's opening are read as teeth and left as they are. The "Hold to see your own" button shows the untouched picture. "Save the picture" writes the canvas to a PNG on your device. On the home page, a colour picker gives any colour. A lip finish changes how the lips are drawn: matte lays more of the flat colour over the lips' own texture, gloss adds a highlight taken from the brightest part of your own lips, shimmer a fine sparkle. "Before and after" puts a divider over the picture, with your own picture to its left; "Keep this look" keeps up to four pictures side by side, in the page only. Under the colours, the colour is put into plain words from its CIELAB lightness, hue and chroma, with plain search links to three shops; for hair, it estimates a level and a tone in words (our own estimate from the screen colour, give or take one level, never a brand's code) and warns when the shade is much lighter than the middle lightness of the hair the model found.


## Measured
On a MacBook Pro (Apple M1 Pro), headless Google Chrome 155, 21 October 2026: 36 ms to find the hair and the lips in a 900 by 1200 picture (GPU delegate), measured 40 times and the middle value taken. "Copy the speed" puts your own numbers on your clipboard with the date and your browser's name. We have not measured how well the models find hair and lips; MediaPipe publishes its figures on the pages linked above.


## What stays on your device
All of it. The page's content rule forbids any request to another host except the Cloudflare visit counter and the link counter at sevenskyconsulting.com, and there is no server of ours behind it: the site is static files. Cloudflare, which serves the pages, counts page visits with its Web Analytics, which sets no cookie: page visits only, never camera frames or photos. Opening your camera asks the browser's permission in the usual way; the stream is drawn to the page and nowhere else. A photo you open is read by the page through a local address the browser makes for it and never sent.


## Where the idea comes from
SeeDeep, a computer-vision project by the same owner, showed a live hair-colour changer in 2025 (its post is kept at seedeep.ai/posts). makeupme.ai was registered in October 2025 and answered nothing until October 2026, when a first page promised: "When something runs here, this page will say what it does and what it keeps, before it asks anyone to try it." This page, built 21 October 2026, is that something.


## Credits
Sample portrait: "Brunette woman portrait" by Christopher Campbell, Wikimedia Commons, CC0, cropped to 900 by 1200.
Typefaces: Montserrat (Julieta Ulanovsky and others) and Playfair Display (Claus Eggers Sørensen), both under the SIL Open Font Licence.
Models and runtime: MediaPipe, Google, Apache 2.0.

Contact: moe@sevenskyconsulting.com.
