Product31 Mar 2026 to now
FaceHush
An on-device face censoring app for photos and video: it finds every face, blurs all of them by default, and lets you tap a person to keep them visible. Nothing is uploaded. Live on the App Store and Google Play.
Built with an AI pair programmer, then reviewed and tested by me. The tests and decision records below are how I hold that work to account.
- Tuning log28dated threshold and model entries
- Recognition model6.8MBfrom 87 MB, same 512-d output
- Tests113Jest app, 29 Vitest site, as the runners count them
The problem
Sharing a photo from a classroom or a party means hiding faces that are not yours to share, usually by hand or through a cloud service. FaceHush does it on the phone. It finds every face in a photo or video, censors them with mosaic, blur, an emoji or a solid cover, and lets you tap the people who should stay visible. Nothing is uploaded.
The failure modes are not symmetric, and that shaped everything. Blurring a face that could have stayed visible is an annoyance. Revealing a face that should have stayed hidden is a privacy failure. Every recognition shortcut had to fail toward blur.
Constraints
- All ML runs on the device. No frames, crops, embeddings or thumbnails leave the phone.
- Store-safe language. The saved-face library is local matching helpers, never biometric identification.
- iOS is Xcode-first: the hand-maintained native project is the source of truth, so expo prebuild --clean is banned. Build 7 went iPhone-only to drop the mandatory iPad screenshot slot for a portrait-locked UI never designed for iPad. The real switch was TARGETED_DEVICE_FAMILY in Xcode; supportsTablet in app.json is inert here, set to false only so the two cannot disagree.
- Specs change in the same commit as behaviour, and a MUST is never quietly downgraded to make a check pass.
What I built
The app is Expo and React Native (SDK 55, React Native 0.83), with native modules where JavaScript was too slow or too far from the pixels. The repositories are private.
- Detection: Google ML Kit for photos, replacing TensorFlow.js, which needed a CDN model download and decoded 12-megapixel JPEGs in JavaScript. Video uses Apple Vision on iOS and MediaPipe on Android.
- Recognition: TFLite embeddings, MobileFaceNet (192-d) on Android and ArcFace with the w600k_mbf backbone (512-d) on iOS.
- Video: a streaming Swift analyzer on AVAssetReader that feeds track events to JavaScript so the preview appears at once, and native exporters on both platforms.
- A Skia censor preview, 9 locales and a Next.js marketing site.
The iOS analyzer is 1,279 lines and the video-only Kotlin 2,020. I built this with an AI pair programmer; every change went through tests and my review.
Decisions that mattered
A face model, not an image-similarity model
Hand-built signatures (raw pixels, histograms, landmark geometry) broke under a shifted crop, new lighting or JPEG compression. Apple Vision's feature print looked like the answer on iOS, but on real photos it matched two different people as one. Tighter thresholds, tighter crops, a pinned revision and an appended landmark vector all failed. The reason is structural: VNGenerateImageFeaturePrintRequest measures how alike two images look, not who is in them. In May 2026 I switched to MobileFaceNet and left Vision in the code, inactive, with a rule not to tune it again.
Thresholds from device logs, never guesses
Diagnostic logs only ran in development builds, so a failed match in TestFlight said nothing. I made them always-on and added a hidden self-test that embeds one photo twice and reports the repeat distance. The first real data point settled it: a same-person pair under different lighting logged 0.4151 against a 0.30 threshold. On 10 May 2026 I moved matching to 0.42 and grouping to 0.45 on both platforms. Android's MobileFaceNet still runs at those; iOS now runs ArcFace at 0.55 match and 0.45 group. Every change since is in a tuning log of 28 dated entries, with a checklist that blocks retrying a failed value.
Default-deny video
For video I first tried to make recognition authoritative: cluster tracks into person cards and let the user split and merge them. On 23 May 2026 I stopped. Every video face is now censored by default, a tap means "keep this person visible", and recognition only assists. The reveal is re-derived on every render from the tapped track's centroid with a strict 0.45 cosine match, so late fragments of the same face join the selection on their own.
Park the native V3 engine
After 16 hours of tuning the React Native video path, I built a native V3 engine in Swift behind a flag: a Kalman filter, Jonker-Volgenant assignment and Core ML embeddings, emitting the same events as v2. Acceptance testing crashed with a SIGABRT inside Vision's object tracker. With the embedder disabled to isolate it, fast camera motion still split one person into 8 tracks, the same limit v2 hits from detecting at about 10 Hz. Smarter association cannot recover detections that never happened. I turned the flag off and kept the sources.
Hard problems
The one-day identity marathon
On 23 May I made 29 commits. The first refinement tightened thresholds and the quality filter together, starving tracks of usable samples and splitting one person into 9 cards. The second reverted the calibration and kept the eye-aligned crops. After the third the pattern was clear: for MobileFaceNet on phone video, same-person and different-person distances overlap too much for any threshold to be safe. That is when I switched to default-deny.
Recognition kept improving as an assistant: ArcFace, then an identity graph with pairwise voting and cannot-link rules. Each threshold guess cost an Xcode rebuild and a device run, so I built an offline Python harness with the app's ArcFace model and a port of its identity graph, at under a second per iteration. On one real clip a single person had been split into 8 tracks, with same-person distances spanning 0.19–0.93. Calibrated thresholds brought them to 2 components.
Memory fixes that became privacy bugs
The app was killed during video analysis. Swapping ArcFace r50 for the mobile backbone had cut the model from 87 MB to 6.8 MB with the same 512-d output, which seemed to justify removing the native sample throttle. It crashed again. The model was never the problem: every matched frame encoded a JPEG crop and pushed it over the React Native bridge faster than the embedding queue drained. The fix bounded crops: every other frame, at most 3 per track, 120 per session.
A busy-scene fix had also capped detections at 12 per frame and open tracks at 8. Review caught what that meant: the 13th face in a frame, or the 9th on screen at once, was never tracked, so it was exported uncensored. I had mixed memory protection with privacy bounds. The invariant is now written down: every valid detection becomes a track and reaches the export censor map, and caps live only where crops are emitted. NMS also went from IoU 0.4 to 0.85, so it stops merging real neighbours.
How it is tested
The app has 113 Jest tests in 13 suites and the marketing site 29 Vitest tests in 3 files, all passing on 27 Sep 2026. Those are the runners' counts; the live proof reading on this page counts test declarations in source instead, so its totals differ. Around them sit type locks, ESLint import guards, XCTest, instrumented tests on the Android emulator, and 4 Detox plus 3 Maestro end-to-end flows, with the fast layers on every pull request and the rest nightly in GitHub Actions. Behaviour lives in seven specs of MUST and SHOULD checkboxes, each with a Verify line. The real-device gate before a release is still a human one.
Before any video code, I locked the photo path four ways: a SHA-256 golden of exported bytes per quality tier, a source snapshot of the photo studio, a tsd lock on the vision API, and an ESLint rule that stops the photo studio importing video modules. I changed video daily for weeks, knowing photos had not moved.
Tests can still lie. Free-tier videos exported without a watermark in Android release builds only, because a runtime asset read returned nothing inside the APK and the instrumented test bypassed that loader; the watermark is now a build-time base64 constant. Analytics opt-out was bypassed on cold start, because the effect ran before saved settings loaded. It now waits for them, and a kill-switch test covers it.
Results
Per the repo's store changelog, Android versionCode 18 was the first public production release, on 5 Jul 2026. On iOS, App Review rejected build 5 under guideline 5.1.1 for declaring tracking without showing the App Tracking Transparency prompt. In August, the prompt, its usage string and the App Privacy declaration moved behind one switch, so they change together. Build 9 went live on the App Store as version 1.0 on 22 Oct 2026, and the app repo has 122 commits.
What I would do next
- Raise the detection rate, which is the ceiling for video tracking.
- Make a tiny or tilted track tappable when it later appears large and frontal.
- Verify the long Pro video cap on real devices. It shipped behind a warning, with export-outcome analytics as the safety net.
Milestones
What shipped, and when.
Started: face censoring that never leaves the phone
Moved to a true face-recognition model
Every threshold change logged against real photos
Every face in a video censored by default
Video on by default on iOS and Android
First production release
Decisions
7 decision records shown here, 1 of them superseded and kept on the list. Open one to read its context and consequence.
A face-recognition model, not an image-similarity model
Use learned face embeddings from MobileFaceNet and keep the Vision path in source, inactive, with a rule not to tune it.- Context
- Apple Vision's feature print measures how alike two images look, not identity, and on real family photos it matched two different people as one.
- Consequence
- Matching became reliable enough to tune from data. iOS later moved to ArcFace, and Android still runs MobileFaceNet.
Every threshold change goes in a tuning log
Each threshold, model or preprocessing change adds a dated entry with hypothesis, exact diff, test method, result and next idea, and a checklist blocks retrying failed values.- Context
- Without a record, recognition tuning drifted into loops that retried values already known to fail.
- Consequence
- The log holds 28 dated entries and makes every tuning decision traceable.
Lock photo behaviour before building video
Freeze photos with SHA-256 goldens of export bytes per quality tier, a source snapshot, a tsd lock on the vision API and an ESLint ban on video imports.- Context
- Video meant large changes in the same app, and photo censoring was the feature people already relied on.
- Consequence
- Photo behaviour stayed provably unchanged through weeks of video work, and a missing golden fails hard.
Person cards with manual split and merge
Cluster tracks into person cards by embedding distance and let the user split and merge them.- Context
- Video needed a way to choose whose face stays visible across a whole clip.
- Consequence
- On phone video the clustering split one person into many cards and could merge different people, so it was replaced the same day.
Censor every video face by default
Censor every detected face and let the user tap a person to keep them visible, with recognition only assisting that choice.- Context
- Same-person and different-person embedding distances overlapped too much on phone video for any threshold to be safe.
- Consequence
- The spec invariant reads: a false blur is acceptable, a false reveal is a privacy bug.
Park the native V3 tracking engine
Turn its flag off and keep the sources so the work can resume without redoing the first two phases.- Context
- A native Swift engine with Kalman filtering, Jonker-Volgenant assignment and Core ML embeddings crashed inside Vision's object tracker and still split one person into 8 tracks under fast motion.
- Consequence
- The v2 pipeline stays in production. Detection rate, not association, is the next lever.
Analytics properties pass an allow-list
Allow exactly 8 property keys with value-shape rules, and send short error codes instead of messages.- Context
- A regex deny-list could be bypassed by innocent-looking key names, and error messages can carry file paths.
- Consequence
- Tests cover the bypass cases found in review, and the SDK never starts for users who opt out.
Live status
Sampled 16 Nov 2026, 02:51 UTC. Failures are shown as they were read.
- Sampling
FaceHush site status
Not sampled yet
Source: facehush.netlify.app
- Sampling
FaceHush on the App Store
Not sampled yet
Source: App Store
- Sampling
FaceHush on Google Play
Not sampled yet
Source: Google Play





