I grabbed a Beddit (
http://www.beddit.com/) off Indiegogo, which does something similar. Compared to Fitbit (put something on; remember to start it), apps (remember to start it) and others, I was hoping it would be frictionless -- hop into bed, start collecting metrics. Unfortunately, aside from the long (long) time required to deliver a useful Android app, it's failed me in a few ways.
1. You need the app running to collect metrics from the device (so, still some friction). I forget the app all the time; at the end of the day, I drop my phone on a charger and crawl into bed. Relying on humans to actively intervene is, unfortunately, suboptimal.
2. I was hoping it'd attach to my wifi and dump metrics to an API I could query (there's no smart alarm, so attaching it to my own stack of stuff seemed cool). Unfortunately, it sends data via a private Bluetooth protocol to your phone, rather than the wifi. Intercepting this is non-trivial (although the Android Bluetooth debugging stack helps). I'm trying to build a receiver on the Pi currently.
3. The API still doesn't really exist.
My use case is slightly different from others. I've got a chronic condition, and I'm not really interested in "did I sleep well last night?", which Beddit seems to have targeted. I'm much more interested in trends over a period of time, once my illness flares -- "am I waking up more often?", "how much time am I spending in bed, rather than active?", "over the past week, how many times have I gotten up -- should I see a doctor?". This should correlate with other smart devices (scales -- "how much weight have I lost?"; fitbit -- "am I still relatively active?") to give me a more holistic view of my health. So, long-term data retention is important to me (CockroachDB looks quite neat!).
Smart alarms and overnight statistics are interesting, but I hope companies developing devices for the quantified self start to pay more attention to long-term health data. It paints a far more interesting story :).