Build low-latency Vision AI applications using our new open-source Vision AI SDK. ⭐️ on GitHub ->

Shipping Real-Time Therapy Conversations with Stream

New
4 min read
Sarah L
Juan Andrade
Sarah L & Juan Andrade
Published October 30, 2025
Building Amy AI with Stream Chat cover image

A senior Android engineer at Argentina's second-largest fintech company, Juan Andrade spent his days shipping features used by millions. But at night, he opened Xcode, taught himself SwiftUI from scratch, and coded until the early hours. His goal was to create a mental health companion that went beyond surface-level validation to provide evidence-based support.

This wasn't a simple iOS app. Building Amy AI required designing an empathetic, real-time chat capable of remembering context, tracking moods, and reframing negative thoughts. To deliver this reliably, Juan needed help. That's where Stream's SwiftUI Chat SDK came in, giving him the tools (and time) to bring Amy AI to life.

From Late-Night Coding to a Mental Health Mission

The spark for Amy AI came from a personal observation. Juan noticed family members leaning on ChatGPT for makeshift virtual therapy sessions. They'd pour out emotions and get back simple affirmations like "You're absolutely right." While comforting, these interactions offered no tools to challenge distorted thinking, no explanations for emotional triggers, and no structured support for real progress.

That gap pushed Juan to act. He wanted to design an app that could deliver something closer to therapy, not a replacement, but a daily companion that helps users reframe harmful thought patterns, track anxiety and mood levels, and receive treatment recommendations grounded in psychological research.

"Mental health support shouldn't just be an echo chamber," Juan explained.

Instead, Amy AI builds on assessments like GAD-7 and PHQ-9, tracks emotional data over time, and integrates cognitive-behavioral therapy (CBT) techniques. The mission was ambitious, but clear. Make evidence-based support accessible to anyone, no matter if they couldn't afford therapy, were stuck on waiting lists, or simply needed help between sessions.

Weekly Progress on Amy AI

Why Real-Time Chat Was Non-Negotiable

For Amy AI, chat is the heart of the product. A therapeutic companion lives and dies by the quality of its conversations. Users need instant responses, empathetic tone, and above all, continuity. Every exchange builds on the last, with context carried over across sessions.

That meant Juan needed to deliver:

  • Real-time message delivery so users could trust the app during vulnerable moments.

  • Session history to track long-term progress.

  • Contextual memory to connect daily check-ins with cognitive reframing exercises.

  • Integration with mood tracking so conversations reflected users' emotional state.

"Chat wasn't just a feature; it was the entire product.""Chat wasn't just a feature; it was the entire product."

Example chat conversation in Amy AI

Despite being an Android specialist, Juan decided to build Amy AI as an iOS app. That meant late nights learning SwiftUI, setting up Xcode, and rebuilding his mental model of mobile development.

On the frontend, he used SwiftUI for the interface, integrated Apple Sign In for authentication, and relied on RevenueCat for subscription management. The Stream SwiftUI Chat SDK powered the chat experience itself, giving him a production-ready interface without weeks of boilerplate work.

The backend ran on Supabase for authentication and a PostgreSQL database, with Node.js cloud functions to handle webhooks. For the AI layer, Juan used the OpenAI API, but with carefully engineered prompts rooted in CBT principles and clinical assessments. He even used Claude Code Pro as a coding companion to speed up iteration while he learned iOS development on the fly.

Not everything was smooth. Managing therapeutic context across conversations while syncing with Supabase became a "technical nightmare." Webhook integration with RevenueCat was another challenge, especially when dealing with subscription renewals mid-session. Even the design was tricky: how do you make a mental health app feel credible without feeling sterile? Juan leaned on feedback from the r/CBT community to strike that balance, prototyping quickly until it clicked.

Start a new conversation on Amy AI

Why Stream Was the Right Choice

At first, Juan tried building chat himself with Supabase's real-time subscriptions. Very quickly, he hit the limits. Ensuring reliable message delivery, handling online presence, supporting typing indicators, and maintaining long conversation histories was too much to reinvent, especially while juggling a full-time job and a brand-new tech stack.

Stream solved those problems out of the box. The SwiftUI SDK was approachable even for a first-time iOS developer, and the documentation was clear enough for Juan to stay productive without hours of trial and error. Most importantly, Stream offered the reliability Amy AI users would depend on.

"Users in distress need to know their messages will be delivered instantly." 

For a mental health app, reliability equates to trust. Stream gave Juan the peace of mind to focus on what made Amy AI unique.

Using GPT Assistants to Accelerate Integration

@juandroid Tweet on building with Stream

Another productivity boost came from OpenAI's GPT Response API, which Juan used as a coding companion while integrating Stream's SwiftUI Chat SDK. As someone brand new to iOS, he expected long nights buried in documentation, but the API helped him stay productive.

"Having an AI that understood Stream's SDK really saved hours."

It explained integration patterns, helped troubleshoot issues, and acted like a Stream SDK mentor available 24/7. Instead of stalling out when stuck, Juan could keep momentum and stay focused on building Amy AI's therapeutic logic.

The impact was huge. With chat infrastructure handled and integration roadblocks cleared, Juan could spend his limited nights coding the features that mattered most: cognitive reframing, mood tracking algorithms, and context-aware conversations

Where Amy AI Is Headed

Amy AI is feature-rich from day one: real-time therapeutic chat, mood tracking, cognitive reframing, session history, and subscription management.

Daily check-in on Amy AI

Next comes listening to users. Juan is planning regression tests, documentation, and gathering feedback from the first cohort. On the roadmap: voice messaging, daily check-ins, and integration with Apple Health for a more holistic view of wellness.

For Juan, shipping Amy AI is only the beginning. The real measure of success will be whether it helps people find support and resilience in their daily lives.

Build Faster With Stream

Looking back, Juan credits Stream for helping him ship faster. 

"Stream probably saved me weeks of development time. Instead of building chat infrastructure, I could focus on the therapeutic AI logic, mood tracking algorithms, and cognitive reframing features that make Amy unique."

That's the story of Amy AI: a solo developer, working nights, building a complex therapeutic app on a brand-new platform. And thanks to Stream, he did it faster, with the reliability his users need.

Start coding with Stream for free. And let Stream's Chat SDKs help you ship faster, too.

Ready to Increase App Engagement?
Integrate Stream’s real-time communication components today and watch your engagement rate grow overnight!
Start Coding Free