About the project
Why we built Somno
Sleep loss does not affect everyone equally. Two people can sleep the same amount yet show very different changes in vigilance, reaction speed and perceived sleepiness.
So instead of building another sleep tracker, we built Somno around a different question:
How far has a person moved from their own normal functional state?
Somno is a multimodal AI system that estimates personal functional readiness under sleep loss using reaction-time performance, facial/ocular evidence, subjective sleepiness and recent sleep history.
How it works
Each Somno check-in combines four evidence streams:
- a short PVT-style reaction test
- a 6-second front-camera fatigue assessment
- KSS-based subjective sleepiness
- recent sleep timing and accumulated sleep debt
Somno then processes these through three core systems:
PRISM — personal-reference multimodal fusion Transforms each signal relative to the user's own baseline and combines only the modalities that are actually available.
BR-GCF — longitudinal uncertainty estimation Tracks uncertainty across repeated measurements from the same person rather than treating every check-in as an isolated prediction.
Certified RASC — adaptive wake control Evaluates optional wake interventions while continuously enforcing deadline feasibility.
What we built
Somno is a functioning Android prototype developed through 27 iterations.
The current implementation contains:
- 21,000+ lines of TypeScript/TSX
- 42 screen modules
- 34 reusable components
- 8 engine modules
- 21 dedicated test scripts
- 4 end-to-end test harnesses
- React Native + TypeScript application logic
- custom Kotlin native alarm infrastructure
- offline core check-ins
- local facial-feature processing
- personal baseline calibration
- sleep-debt and longitudinal tracking
- reboot-resilient alarm scheduling
Signed APK and Android App Bundle builds have also been produced.
Results
We evaluated Somno across human sleep-restriction data, controlled AI experiments and 1.2 million+ simulated decision episodes.
Personal-baseline evidence
Across 180 repeated reaction-time observations from 18 sleep-restricted participants, the association between study day and reaction time increased from:
$$ \rho = 0.523 $$
to
$$ \rho = 0.621 $$
after representing performance relative to each participant's personal baseline.
Rested-vs-late-restriction discrimination increased from:
$$ AUC = 0.843 \rightarrow \approx 0.900 $$
and 17 of 18 participants showed positive reaction-time deterioration slopes.
By Day 9, reaction time was an average of 88.7 ms slower than personal reference.
PRISM multimodal fusion
Mean absolute error decreased from:
$$ 0.726 \rightarrow 0.598 $$
compared with population-fixed fusion.
BR-GCF uncertainty
At a nominal 90% target, whole-subject coverage reached:
- 91.17% with complete sensing
- 89.33% with 35% missing data
- 89.00% with 65% missing data
- 88.17% under a quality-signaled facial shift
Certified RASC
Across 600,000 simulated alarm episodes:
0 deadline misses
In a benefit-dominant environment, harmful snooze decisions fell from:
$$ 20.06\% \rightarrow 0.02\% $$
In a heterogeneous environment:
$$ 24.12\% \rightarrow 0\% $$
Consequence-aware decision gating
Across another 600,000-case stress test, with 50% missing evidence:
$$ 4.71\% \rightarrow 0.32\% $$
false reassurance among accepted decisions.
Challenges we faced
Somno's later iterations were driven by real engineering failures rather than simply adding features.
A face-validity issue that could accept walls or palms led us to build hard detector gates and negative controls.
An unstable sleep-debt feedback path was replaced with a bounded leaky accumulator.
Alarm execution was moved below JavaScript into native Android scheduling with persistent state, reboot recovery and full-screen execution.
Missing evidence was redesigned so unavailable sensors remain missing, instead of silently becoming artificial values.
Representative verification now includes:
- 127/127 tap-driven navigation transitions
- 42 sleep-debt engine checks
- wall, surface and palm rejection tests
- testing across 4 time zones
- native alarm re-arm, reboot, snooze, stop and next-day scheduling verification
What we learned
The strongest improvement did not come from simply using a more complicated model.
It came from making the system personal.
Somno showed that representing reaction performance relative to someone's own baseline can reveal changes that population-level measurements blur, while multimodal fusion and uncertainty estimation make that personal signal usable even when real-world mobile data are incomplete.
That led to the principle behind the entire project:
Your normal should be the baseline—not everyone else's.
Somno turns that principle into a working AI system for measuring, understanding and responding to personal functional readiness under sleep loss.
Built With
- ai
- android
- biometrics
- calibration
- conformal
- edgeai
- explainability
- fatigue
- inference
- kotlin
- ml
- mobile
- multimodal
- personalization
- privacy
- pvt
- reactnative
- readiness
- safety
- sleep
- temporal
- typescript
- uncertainty
- vision
- wellness