Inspiration

A three-year-old asks "why?" hundreds of times a day. Each one is a small door opening. But parents are tired, the dinner is burning, and too many of those doors swing shut with "I don't know, sweetie."

I wanted a buddy who could catch those questions, so that no "why?" goes unanswered. As I looked at the AI toys already out there, I got scared. One AI plush toy leaked tens of thousands of children's conversations from its backend. A beloved AI robot stopped working when the company's cloud shut down. In almost every product, the child's voice, face and questions travel to a server the parent can't see.

So I started from one rule:

The phone is the only place a child's data exists. The cloud only ever talks to the parent.

Grasp is what you get when you build a toddler's AI companion around that rule, and give the parent something precious in return: a window into how their child's curiosity is growing.

What it does

  • The child asks anything, by voice or by showing a photo. A friendly buddy answers in two or three gentle sentences, suggests a real-world thing to try with a grown-up, and offers follow-up questions.
  • Every answer comes from Gemini Nano, on the phone. It works in airplane mode. If Nano isn't available, the buddy says "Let's ask your grown-up!" There is no silent cloud fallback for children.
  • Big questions go to the grown-up. Questions about death, illness, bodies, family conflict or danger never reach the model. The child hears "Big questions feel best with someone who loves you," and the parent gets a private "talk about this together" card.
  • Parents get a curiosity map showing which worlds their child is exploring (space, living things, how things work…) and how deep their questions go, from noticing to imagining.
  • An optional weekly note is written in the cloud, but only from an anonymous digest the parent reads before tapping Send.

How I built it

Grasp is a native Android app in Kotlin + Jetpack Compose, using Firebase AI Logic's hybrid inference:

Model Inference mode What it sees
childModel ONLY_ON_DEVICE (Gemini Nano) The child's question or photo, in RAM, for one turn
reportModel PREFER_IN_CLOUD (Gemini Flash) Only the ParentDigest: enums, buckets and vocabulary IDs

The child's turn. Speech is recognized on device, then passes an input guard before Nano is ever called. Nano returns strict JSON (answer, domain, topicKey, level, followUps, …). An output guard checks length and blocks words a toddler companion should never say ("secret", "best friend", "don't tell"). The raw text is then dropped. Only a closed-vocabulary QuestionEvent (enums and IDs, never free text) is written to the ledger. A free-text field could one day hold "Grandma has cancer." An enum can't.

The curiosity graph is a pure-Kotlin scoring engine with no I/O. A topic's interest decays with a two-week half-life:

$$ \text{Interest}(n) = \sum_{e \in E_n} 0.5^{\,(t_{\text{today}} - t_e)/14} $$

and depth is the rolling median of the question level $\ell \in {1,\dots,5}$ over the last 7 questions in a domain, mapped to a stage: Noticing → Describing → Wondering how → Asking why → Imagining.

The Privacy Firewall is the only module allowed to build a cloud payload, and its input type can see only weekly aggregates. It:

  1. Coarsens counts into buckets: $c \mapsto {1,\ 2\text{–}3,\ 4\text{–}7,\ 8{+}}$
  2. Thresholds them, dropping any domain with $c < 2$ this week, so one odd question never shapes a report
  3. Suppresses sensitive categories entirely, sending only how many talk-together cards exist
  4. Contains no identifiers: no name, no UID, no timestamps finer than a week

The parent sees the exact JSON on a "What Grasp will send" screen before anything leaves the phone. When the report comes back, the device validates it: any recommended book or activity that wasn't in the candidate list the app sent is discarded, and any text that ranks or labels the child ("gifted", "ahead", percentiles) is rejected.

Firebase also gives Grasp App Check, Anonymous Auth (the cloud identity is the parent's install, never the child), and Firestore rules that only allow public catalog reads plus write-only flags for answers a parent reports as wrong. Without Firebase config, the app runs in a clearly badged Demo mode with synthetic data, so anyone can try it.

Challenges I ran into

  • Making privacy impossible to break by accident. "We promise not to log it" is a policy. I wanted something the code enforces: closed vocabularies, types that can't carry free text, and a single module that is allowed to touch the cloud model.
  • Failing closed felt wrong at first. Every instinct says "fall back to the cloud so the feature works." I chose to let the child see "ask a grown-up" instead. That turned out to be the most honest moment in the demo.
  • On-device prompting. It wasn't clear whether on-device inference honors system instructions, so I resend the persona and safety rules with every turn and keep every turn single-shot, with no chat memory to drift.
  • Toddler speech is hard. Speech recognition on two-year-olds is unproven, so I made "grown-up types it" a first-class input path rather than an afterthought.
  • Hallucinated recommendations. The cloud model sometimes invented catalog items. Validating every pick against the IDs the app sent fixed that and also blocks prompt injection.
  • Tone. It's easy for a report to sound like a school ranking. I rewrote prompts and added output filters so the report talks about process ("they've started asking how things work") and never about ability.

Accomplishments that I'm proud of

  • A child can use Grasp in airplane mode, and the curiosity map still works.
  • The only child-derived data that ever leaves the phone is a few lines of JSON the parent has read, with no words, names or photos in it.
  • The sensitive-topic path: the app never tries to explain death to a three-year-old. It hands that moment back to the person who loves them.

What I learned

  • Privacy is an architecture, not a setting. The strongest guarantee is data that never exists on a server at all: nothing to leak, subpoena or shut down.
  • Hybrid inference changes product design. With Nano on device and Gemini in the cloud, you can decide per feature, and per audience, where intelligence runs. Kids on device, parents in the cloud.
  • Constraints made it warmer. Short answers, no "I love you", no streaks, and a nudge back to a real grown-up made Grasp feel less like a gadget and more like a gentle bridge between a child and their parent.

What's next for Grasp

  • Encrypted on-device ledger (SQLCipher + Android Keystore) with one-tap "delete everything" crypto-shredding
  • Parent sign-in with verifiable parental consent (COPPA, India's DPDP rules)
  • End-to-end encrypted sync between two parents' phones over a QR-code key exchange
  • A larger, editorially reviewed catalog of books, audio and offline activities
  • Measuring speech recognition on real toddler voices, with families who opt in

Built With

  • ajv
  • android
  • android-speechrecognizer
  • android-studio
  • android-text-to-speech
  • cloud-firestore
  • firebase
  • firebase-admin-sdk
  • firebase-ai-logic
  • firebase-app-check
  • firebase-auth
  • firebase-emulator-suite
  • firebase-remote-config
  • gemini
  • gemini-flash
  • gemini-nano
  • gradle
  • jetpack-compose
  • junit
  • kotlin
  • kotlin-coroutines
  • kotlinx-serialization
  • material-design-3
  • node.js
Share this project:

Updates

Submission history