Build a focus-quality tracker. The output is not a dashboard, it is two numbers and one suggestion. Stack: a local recorder plus a dashboard, SQLite, no network. Build on an existing open-source capture layer if you can. From the raw activity stream, derive sessions: - A session starts when activity in one category persists past a minimum length. - A switch to a different category shorter than a configurable tolerance is an **interruption** — it is counted but does not end the session, which is what makes this measure meaningful. A longer switch ends it. - Store per session: category, start, end, and the interruption count. The two numbers: 1. **Median uninterrupted stretch** — the median run of activity within sessions between interruptions. Median, not mean, because one four-hour Sunday ruins a mean. 2. **Peak focus window** — bucket the last four weeks of session time by hour of day, weight by uninterrupted stretch length, and name the two-hour window that scores highest. The daily suggestion, exactly one, chosen by a small set of explicit rules you can read in the code — for example: if today's interruption rate is above the four-week median, name the application that caused the most interruptions; if the peak window contained meetings, say so and name the meeting hours; if no session reached the minimum length all day, say that plainly. Never generate more than one, and never generate a vague one. Break tracking: detect gaps over a threshold as breaks, show breaks taken per working hour, and flag a day with a long continuous stretch and no break rather than congratulating it. Dashboard: today's sessions as a timeline with interruptions marked, the two numbers with their four-week trend, and the suggestion at the top. Privacy: pause control, title redaction per application, raw retention window, wipe command. Write tests for interruption-versus-session-end at the tolerance boundary, for median computation on an even count, and for the peak-window calculation with fewer than four weeks of data (it must decline to answer rather than guess). Do not build calendar integration, cloud sync, or a team view.