DoseKeeper is a deployed Flutter/Riverpod care-coordination demo built around one deliberately strict idea: taken, missed, and not marked are three different states. A person marks a dose in the Patient view, and the Caregiver and Provider views react to the same persisted state graph without screens passing data to one another.
The care circle and medication names are fictional. DoseKeeper is a personal/family coordination demo, not a medical device. It does not provide dosage guidance, interaction checking, reminders guaranteed to fire, or medical advice.
Open the live demo · Read the design contract · Inspect the CI
No account or setup is required. The banner identifies the bundled family as fictional.
- In Grandma Rose, mark an amber dose as taken.
- Open Caregiver. The attention count and Rose's status update from the same state mutation—no refresh.
- Open Provider. The identical event appears in the live Today panel and the three-state history.
- Move the labeled Demo clock beyond a dose window. The app asks a human to distinguish “missed” from “taken, forgot to mark”; it never guesses.
- Correct or undo the answer and watch every perspective reconcile again.
| Patient mutation | Caregiver consequence | Provider consequence |
|---|---|---|
![]() |
![]() |
![]() |
| Claim | Verifiable evidence |
|---|---|
| One state graph feeds five role views | Riverpod derived providers over careCircleProvider; widget tests perform a Patient tap and assert Caregiver and Provider output. |
| The three-state invariant survives time and reloads | Domain, persistence, injected-clock, threshold, rollover, and correction tests run in CI. |
| It ships, rather than stopping at screenshots | GitHub Pages builds and deploys the web release; a separate Windows runner compiles the x64 bundle. |
| The architecture has a defined boundary | LocalRepo implements the repository contract today; cloud sync is explicitly a future implementation, not a current claim. |
- Five perspectives, one state graph: Patient, Caregiver, Provider, Circle, and Settings all watch Riverpod providers derived from one persisted care-circle snapshot.
- A visible cross-role invariant: tapping the amber “Taken?” action changes the Patient dose, Caregiver attention count, Provider Today panel, and relevant badges immediately.
- Three-state integrity: an unresolved dose stays amber and remains
notMarked; only a human can resolve it as greentakenor redmissed. - Human escalation: a labeled demo clock moves a dose from heads-up to window-closing to “Did you take it and forget to mark it, or did you miss it?”
- Correctable history: a mistaken answer can be corrected or undone, with the same update propagating everywhere.
- Deterministic time behavior: injected date/time providers make threshold and midnight-rollover behavior testable instead of depending on the wall clock.
- Offline persistence behind a boundary:
LocalRepostores JSON withshared_preferencesand exposes a watch contract. A future synchronized repository can feed the same state layer; Firestore is not implemented in v0.1.
| View | Purpose |
|---|---|
| Patient | Large, simple dose cards; mark taken; answer unresolved-dose questions; correct an entry. |
| Caregiver | Prioritized attention list and per-person today/week status, including confirmed misses. |
| Provider | A live Today panel plus date-range history that preserves taken/missed/not-marked distinctions. |
| Circle | Read-only fictional people, medications, and human-readable schedules. |
| Settings | Demo-clock explanation, example-data reset, persistence state, and safety/disclaimer information. |
These are deterministic 1440×1000 captures of the full Flutter widget tree with the bundled fictional family—not mockups.
| Circle | Settings |
|---|---|
![]() |
![]() |
docs/screenshots/ contains the reproducible capture command and state contract.
flowchart LR
UI["Patient · Caregiver · Provider · Circle · Settings"]
DERIVED["Riverpod derived providers<br/>today · attention · adherence · settings"]
STORE["careCircleProvider<br/>single in-memory source of truth"]
REPO["Repository watch/save contract"]
LOCAL["LocalRepo<br/>shared_preferences JSON"]
FUTURE["Future sync repository<br/>not included in v0.1"]
UI -->|watch| DERIVED
UI -->|mutate| STORE
STORE --> DERIVED
STORE <--> REPO
REPO <--> LOCAL
FUTURE -. same contract .-> REPO
The UI never passes a mutated model from one role screen to another. It sends an intent to the notifier; derived providers recompute, and every interested view rebuilds from the new snapshot. Persistence writes are kept behind the repository rather than embedded in widgets.
The event key is a schedule slot plus local calendar date. An event records taken (including when it was recorded), missed (explicitly confirmed), or no event, which derives to notMarked. Known-history boundaries keep dates outside the seeded data from being reported as non-adherence.
Prerequisites: Flutter 3.44.6 stable (Dart 3.12.2) and a web-capable device.
git clone https://github.com/Xyloth/dosekeeper.git
cd dosekeeper/app
flutter pub get
flutter run -d chromeThe app opens with a clearly labeled fictional family. Use Demo clock to cross a dose-window boundary without changing the computer clock. Use Settings → Reset fictional example family to restore the known starting state.
For Windows desktop:
flutter config --enable-windows-desktop
flutter run -d windowsWindows plugin builds require symlink support. Enable Windows Developer Mode if Flutter reports that plugins cannot create symlinks.
Run the same gates used in CI:
cd app
dart format --output=none --set-exit-if-changed lib test
flutter analyze
flutter test
flutter build web --releaseThe tests cover domain-state integrity, persistence/reload behavior, time boundaries, selection stability, and the headline widget flow: a Patient interaction updates Caregiver and Provider UI from shared state.
pages.yml builds with the repository base path and deploys the release artifact to GitHub Pages on pushes to main. In repository settings, choose GitHub Actions as the Pages source. The workflow requests only contents: read, pages: write, and the OIDC permission required by Pages.
windows.yml is a manual bonus-platform build so normal pull requests do not spend Windows runner minutes. ci.yml enforces formatting, analysis, tests, and the web release build.
v0.1 has no accounts, server, analytics, PHI workflow, OS notifications, drug database, or cloud synchronization. Data remains in the browser/app’s local preferences. Clearing site/app storage removes it. Do not enter real health information into this portfolio demo.
See DESIGN.md for the product decisions and CHANGELOG.md for the current verification state.
MIT © 2026 James Dye. See LICENSE.




