Inspiration

63 million Americans care for a family member (AARP and NAC, 2025), and much of that care is paperwork: Mom's patient-portal message, a pharmacy refill notice, an insurance statement, a bill. Those documents carry a family's most private data, and today the usual AI option is to upload all of it to a cloud. Caregivers also split the work with siblings over group texts that lose track of who is doing what and by when.

What it does

  1. Paste a portal message or email, or add a photo of a paper letter.
  2. Gemini Nano reads it on the caregiver's own computer through Firebase AI Logic and returns a plain summary, "What to do" cards with suggested dates from the letter, and questions to ask the care team. English and Spanish. Read aloud uses the browser's own speech.
  3. Kinfold never sets a deadline by itself. Code checks every date the AI proposes: it must be in the pasted letter, in the part of the sentence that names that task, and not negated. A date that passes is shown as suggested, and becomes the deadline only when the caregiver taps it; a date that fails is removed and flagged. These are word-matching rules, so a suggestion can be wrong (our reviewer wrote letters that fool them), which is why a person confirms every date. Dates read from a photo are flagged for the caregiver to check against the paper. (The demo video was recorded before this last change: it shows dates set directly.)
  4. The caregiver adds tasks (not documents) to a family plan and invites siblings with a private link. Anyone can tap "I'll do it" and tick it off.
  5. One tap and Gemini writes a short group-chat update from the task lines only (in the cloud; if the cloud can't be reached, the app writes it in code from the task lines). Helper names are swapped for placeholders before the cloud call and restored on the device.

How we built it: Firebase AI Logic hybrid inference

  • Three models with three privacy rules (src/ai.js):
    • Reader: InferenceMode.ONLY_ON_DEVICE, with text and image input and a JSON responseConstraint schema.
    • Cloud reader: ONLY_IN_CLOUD (Gemini 3.1 Flash-Lite). It is used only on devices with no local model, and only after an explicit consent screen for that one document.
    • Family writer: ONLY_IN_CLOUD with a 20-second limit; if the cloud can't be reached, code writes the update from the task lines. We started with PREFER_IN_CLOUD, but its on-device fallback invented chores and dates in 5 of 5 offline drafts, and a call made while Gemini Nano was warming up hung for minutes. Cloud text that mentions a date that isn't a task's date (year included when given) is rejected. It sees only approved task lines; helper names are swapped for placeholders.
    • Why not PREFER_ON_DEVICE for the reader? Its automatic fallback would send a private health letter to the cloud without asking. Kinfold keeps the reader on the device and asks first.
  • Every result shows where it ran (inferenceSource) and how many seconds it took.
  • The model is woken in the background when the page opens, so the slow first load happens before the caregiver needs it.
  • Firebase App Check (reCAPTCHA Enterprise) is enforced on AI Logic. Anonymous Auth and Cloud Firestore hold the shared plan. The app blocks ID numbers and emails before a task is shared, and Firestore rules re-check on the server: a fixed task shape, no unbroken 8+ digit runs, no email addresses.
  • React + Vite on Vercel. 28 unit tests cover the date check, the share guard, the family-update check, translation merging and name handling.

Challenges we ran into

  • Invented dates. On our 2019 Intel MacBook (CPU-only inference), Gemini Nano turned "call by December 12" into a date in February 2027. We stopped trusting model dates: code verifies each date in pasted text against the document (English and Spanish date formats, year-aware), and dates read from photos are flagged for the caregiver to check.
  • Spanish output. Asking for Spanish in one pass gave English back. A second on-device step translates the reading, and code keeps the original dates and task types.
  • Cold start. Before our warm-up fix, the first on-device read took 54–111 s on that Mac. Warm reads take 5–13 s. The app now wakes the model through Firebase AI Logic on page load; the first real read after that took 9.0 s.
  • The on-device writer invented chores. Offline, Gemini Nano added groceries, laundry and dates that weren't on any task in 5 of 5 drafts. A call made while the model warmed up also hung for minutes. The writer is now cloud-only, and code writes the update when the cloud can't be reached.
  • The cloud writer invented progress ("I finished the laundry") in an early test. Code now builds separate done and open lists, writes the closing question and rejects dates that aren't a task's date. A draft can still word things loosely, so the caregiver reads it before sending.

Accomplishments we're proud of

  • The whole document never leaves the device on a capable computer, and the app tells you where each step ran.
  • The caregiver, not the AI, has the final say on dates (code checks them and only suggests), and code decides what can be shared.

What we learned

On-device models are good at structure (finding tasks) and weak at exact facts (dates). Hybrid works best when code checks the facts and the cloud only sees what the user approved.

What's next

Kinfold for iPhone and Android is in development with Expo and coming soon to the App Store and Google Play (not yet released or tested on a device). It is designed to read the photo with Apple Vision on the phone, use Apple's on-device model where Apple Intelligence is on, and send only text to Gemini through Firebase AI Logic, with consent, on other iPhones. Work in progress: https://github.com/aizoya/kinfold/tree/claude/ios. An Android app is planned from the same Expo code. Also a Chrome side panel that reads the patient portal page already open, and calendar export. Planned pricing (not yet tested with customers): free for one family; Family Plus at $6/month (unlimited documents, more caregivers, reminders). Agencies and employers can offer it as a caregiver benefit.

Testing instructions for judges

Open https://kinfold.aizoya.com in desktop Chrome. If Chrome hasn't downloaded Gemini Nano yet, click "Get private reading ready" (a one-time download of a few GB; see Chrome's built-in AI hardware requirements), or use the cloud option, which asks first. Once the model is on the computer, the app wakes it on page load; give it 1–3 minutes on an older laptop after Chrome starts (the Read button waits until it is ready, and a private read that runs past 90 s stops with a retry message instead of switching to the cloud), then pick a fictional sample and click "Read it privately" (5–13 s per read on our 2019 Intel Mac once warm). Then tap a suggested date to set the deadline, add the task to the family plan, create a family link, open it in a second window and tick the task off. On a device with no on-device model, the app offers cloud reading after a consent screen (tested Nov 30 in desktop Chrome with the on-device model marked unavailable: 1.8 s through App Check; then on an iPhone 13 Pro Max: 2.8 s, date found in the letter). All samples are fictional.

Built during the submission period

All code was written Nov 29–30, 2026, after submissions opened on Nov 11. Earlier work was research only (competitor repos, rules, a Prompt API speed test on the same Mac). No pre-existing code was reused.

AI-use disclosure

Built during the submission period by AIZOYA (Franklyn Rosario), with Claude (Anthropic) as the coding assistant.

Judges page with the video, test steps and design notes: https://kinfold.aizoya.com/judges/

Built With

  • chrome-prompt-api
  • cloud-firestore
  • firebase-ai-logic
  • firebase-app-check
  • firebase-authentication
  • gemini
  • gemini-nano
  • react
  • vercel
  • vite
Share this project:

Updates

Submission history