Inspiration

Born out of a desire to become more familiar with my health data and be able to interact with it in a conversational way. I wanted to create something that would change peoples lives by allowing them to have better conversations about their health so that when they see health care professionals they can engage in those conversations.

Health Kitty is a project that is designed to improve peoples lives and remove the barriers to understanding your health data.

What it does

Health Kitty is a conversational app that allows for asking questions about your health data and finding out the responses. You can ask questions such as "How long did I sleep last night" and "what was my heart rate this morning" to find out the details.

Rather than have the user navigate through a hierarchy of data to find the right details, using a conversational approach means that you can find the answers to your questions easily.

By creating notes from the data, you can then have easy access to the data when you talk to doctors and other healthcare professionals.

How we built it

The approach taken with Health Kitty is deliberately simple in that it uses first party frameworks on iOS for the majority of the app. These include.

  • SwiftUI
  • SwiftData
  • FoundationModels
  • Swift Charts
  • StoreKit
  • HealthKit

To help with showing a subscription prompt (paywall) the RevenueCat SDK is included. This is the only 3rd party SDK which is defined as a dependency.

Challenges we ran into

As health data can get very large and complex very quickly, being able to respond to the Tool call with the right data becomes complex. This is because if there's too much data in the tool response then FoundationModels will exceed the token window size. A lot of trial and error was required to find the correct balance here. Using the Playground macro in Xcode along with unit tests allowed for rapid iteration over the data.

Accomplishments that we're proud of

Releasing a product that impacts and changes the way people have conversations about their health is a huge accomplishment.

Providing an app that makes use of FoundationModels to get the data from HealthKit is a great achievement and a lot of fun to work with.

What we learned

A big thing learnt was how to make use of FoundationModels to provide the desired interactions and answers to the users questions.

What's next for Health Kitty

  • Fine tuning of responses by adjusting instructions and prompts
  • Access to more data in Apple Health via the HealthKit framework
  • Access to clinical documents
  • Allow the user to create upcoming appointment reminders via the app and attach notes about relevant health data

Built With

  • foundationmodels
  • swift
  • swiftui
Share this project:

Updates