Question
How can a break-reminder application measure meaningful computer activity without monitoring what a person types, clicks, reads, or views?
LAB 004 / RESEARCH
Modeling trustworthy focus and away boundaries from minimal Windows activity signals.
01 / LAB NOTES
How can a break-reminder application measure meaningful computer activity without monitoring what a person types, clicks, reads, or views?
The tracker should use only elapsed idle duration and operating-system lifecycle signals. It must not collect keystrokes, pointer coordinates, screenshots, open documents, or application content. Its history should also survive lock, sleep, suspend, timer stalls, and application restarts without inventing focus time.
Represent the day as wall-clock segments rather than a single accumulated timer. Verified active ticks extend a focus segment. Crossing the configured idle threshold closes that segment at the last recorded input and removes the threshold’s idle tail. Returning closes the away segment and begins a new focus session.
Lock and suspend signals close activity immediately. An unusually large gap between timer ticks is treated conservatively as away time, and an open segment found after restart is closed rather than stretched across the shutdown.
Pure activity functions were separated from Electron window and tray code, then exercised with deterministic tests for idle-tail correction, away-to-focus transitions, session resets, and stale restart state.
The resulting timeline preserves real clock position and excludes idle grace periods from focused work. That makes reminder thresholds and daily rhythm views more credible while retaining a narrow privacy boundary.
Moved session-boundary logic into a pure module, made the Electron main process the single runtime authority, and treated uncertainty—sleep, restart, or missed ticks—as away time instead of assuming continued focus.
TOOLS & TECHNOLOGIES