Inspiration
My younger sister asked me to tell her a story, but she kept interrupting—"No, make the squirrel fly to the moon!" "Wait, give him a laser!" That's when it hit me: What if a story could actually LISTEN and adapt? What if kids could become co-creators instead of just listeners?
What It Does
StoryLives is an interactive storyteller where kids co-create magical adventures with Lumi, an AI narrator they can talk to naturally. Children can interrupt to change directions, and watch their choices generate unique illustrations in real-time, while creating a living storybook that adapts to their imagination.
How I Built It
- Frontend: React + Vite with Web Audio API for voice capture
- Backend: Python FastAPI with WebSocket connections for real-time communication
- AI/ML: Google's Gemini Live API for natural conversation + Imagen on Vertex AI for illustrations
- Cloud: Deployed on Google Cloud Run (serverless, scales to zero)
- Caching: Cloud Storage with intelligent prompt hashing to minimize API costs
Challenges I Faced
- Real-time interruptions: Making Lumi pause mid-sentence when a child speaks was tricky! WebSocket bidirectional streaming was the key.
- Image generation latency: Kids won't wait 5 seconds for pictures. Solved with parallel generation, and narrating while rendering next scene.
- Billing setup: The $10 prepayment hurdle was real, but now we're live!
What I Learned
- Gemini Live API is GAME-CHANGING for natural conversation
- Kids have WILD imaginations—our story graph needs to handle ANY direction
- Serverless doesn't mean costless—caching is your best friend
What's Next
- Add multiple story genres (space, dinosaurs, underwater)
- Let kids draw characters and have Lumi recognize them (vision input!)
- Deploy on more regions for lower latency worldwide
Built With
- cloud-storage
- docker
- fastapi
- gemini-live-api
- google-cloud-run
- imagen
- python
- react
- redis
- vertex-ai
- vite
- web-audio-api
- websockets
Log in or sign up for Devpost to join the conversation.