LivaFast
Privacy-first fasting and liver-health tracking for iPhone and Apple Watch.
Indie project · Solo designer & developer · 2026 · iOS 26 / watchOS 26
Visit livafast.com →- Swift packages
- 25
- automated tests
- 888
- lines of Swift
- ~124k
- commits co-authored with Claude
- 528 / 687








The idea
Fatty liver disease affects about a quarter of adults, and intermittent fasting is one of the lifestyle levers people use to manage it. Most fasting apps, though, treat fasting as a weight-loss timer. LivaFast connects each fast to the thing the user actually cares about, their liver, and keeps all of that sensitive health data private.
Why I built it
LivaFast is a deliberate stretch project. I wanted to learn whether agentic development with Claude Code could produce software I’d be proud to put my name on: modular, testable, concurrency-safe, and using the newest Apple platform features. “Working demo” quality wasn’t the goal.
What it does
- Fasting engine: 11 protocols, from 12:12 to extended fasts and custom schedules. Live metabolic stages show the user moving from glycogen depletion through ketosis to autophagy.
- Liver Progress Score: A 0–100 score with four weighted parts: steatosis (Fatty Liver Index / HSI), fibrosis (FIB-4), metabolic markers (HOMA-IR, lipids, waist-to-height ratio) and lifestyle (fasting, sleep, exercise, resting heart rate). It is smoothed so a single missed fast doesn’t move it, and it refreshes daily in the background.
- Labs & doctor visits: Users log their own lab values (ALT, AST, GGT, HbA1c, lipids), see trends in Swift Charts, and export a PDF of talking points for their doctor.
- LiVA, the on-device coach: Built on Apple’s Foundation Models, with 17 prompt types: weekly summaries, lab explanations, heart-rate and steps analysis per fast, questions to ask your doctor, and more. When Apple Intelligence isn’t available, a rule-based engine takes over.
- Journey & challenges: A 12-week Liver Reset with phases and milestones, plus 8 structured challenges tracked by a slot-based compliance engine.
- Learn & listen: 25 articles, two illustrated serialized stories (55 chapters), and a podcast season with lock-screen playback.
Across Apple’s ecosystem
- Apple Watch: Start and end fasts (including challenge fasts) without the iPhone, writing directly to CloudKit. Includes complications in every accessory family and a Control Widget backed by App Intents.
- Widgets & Live Activities: Home Screen widgets in three sizes, and a Live Activity with Dynamic Island for the running fast.
- HealthKit: Reads 11 data types (heart rate, HRV, sleep, steps, body composition, glucose…) with background delivery.
- Apple-Hosted Background Assets: The podcast season ships as an Apple-hosted asset pack instead of being bundled in the app. Scripts package it with ba-package and upload it through the App Store Connect API, so episodes can be updated without an app review.
- StoreKit 2: Freemium model with one Premium purchase and a fully custom paywall, enforced on both iPhone and Watch.
Architecture
- 25 Swift packages: Each split into an Interface target (protocols and Sendable models) and a Live target (implementations). Modules depend only on each other’s interfaces. The app target wires the live implementations together through dependency injection, so every feature can be tested in isolation.
- Swift 6 complete strict concurrency: MainActor is the default isolation. Actors own all mutable shared state (fasting sessions, HealthKit, CloudKit sync, the AI model, lab values), and @Observable view models run on the main actor.
- MVVM + Coordinators: A five-tab app with a livafast:// deep-link pipeline.
- 888 tests: Written with Swift Testing, covering domain logic, the score calculation, SwiftData models, CloudKit conflict resolution and the challenge engine.
Privacy & security by design
- No accounts, analytics, ads or tracking SDKs.
- Data lives on the device and in the user’s own CloudKit private database.
- AI inference never leaves the phone.
- Optional Face ID / Touch ID / Optic ID app lock, settings stored in the Keychain, explicit consent during onboarding, a privacy manifest, and one-tap deletion of all data.
How I built it: agentic development
I worked with Claude Code as a pair-programmer throughout:
- Every feature went through brainstorm → written spec → implementation plan → test-driven implementation → review. That produced 21 specs and 23 plans, kept in the repo.
- Project rules in CLAUDE.md kept the agent consistent with the architecture. I also used custom skills, and drove builds and simulators through XcodeBuildMCP.
- Pre-launch audits (App Store readiness, accessibility, privacy) were run as agent tasks.
- Over about three and a half months, 528 of 687 commits were co-authored with Claude.
I also used AI for visual content. A prompt book defines reference portraits for each character first, and every chapter cover reuses those references with a fixed style line. That system produced 200+ illustrations with consistent characters across the stories and articles. The podcast is hosted by two AI personas.
What I learned
- Agents amplify whatever structure you give them. Strict module boundaries, a clear CLAUDE.md and spec-first planning were what turned fast output into maintainable code.
- With Swift 6 strict concurrency, the compiler acts as a second reviewer. It caught whole classes of bugs before an agent or I ever ran the app.
- On-device AI changes the product conversation: with no server, no data retention policy is needed and there’s no privacy trade-off to explain.