46 karma · joined Jul 11, 2023 (3y ago) · 5 submissions
comment 3y ago · link · parent
> My average sleep efficiency (time asleep vs time in bed) according to Apple Watch & Oura is ~85%, meaning to get my 7h30 of sleep to feel rested I will stay more than 10h in bed. That sucks!
1. Where does the 10h figure here come from? It seems to me that 85% SE would reach 7h30 sleep hours at 8h50m bed hours (7.5/0.85).
2. What is an expected healthy sleep efficiency? Does 85% fall outside the normal range?
3. Where does the 7h30 target come from? If this is based on the standard adult recommendation of 7-8 hours, are we sure that this recommendation assumes 100% SE? If it doesn't, we're mixing different units.
comment 3y ago · link · parent
I'm not aware of anything exactly like Livebook in the Kotlin ecosystem but you might be interested in kotlinx-knit which takers a more incremental approach to executable documentation:
https://github.com/Kotlin/kotlinx-knit
Neither of these approaches will result in interactive documentation.
comment 3y ago · link · parent
I've been working on something like this for Kotlin using a compiler plugin that allows code to access the source text of lambdas, functions and classes being executed. You write code that spits out markdown and captures its own source into code blocks.