Inspiration
SerenAI was born out of a deep desire to make mental health support more human, more accessible, and more insightful—without losing the soul in the science.
I noticed that most chatbot solutions in mental health simply give canned advice or mimic empathy. But what if an AI assistant could go beyond surface-level support? What if it could understand not just the words, but the emotions, the trends, and even the urgency—and present that insight to both the user and the therapist?
I personally witnessed the silence many people feel—too scared to open up, too confused to explain what they’re going through. I wanted SerenAI to be a safe space to start that conversation, and a bridge to the therapist on the other side who wants to help.
What it does
SerenAI is a soothing mental health chatbot that lets users talk about their feelings in a calm, welcoming interface—and does a lot more under the hood:
-🧠 Emotion detection after every message using nomic-embed-text + an emotion classification model.
-🚨 Crisis risk scoring to determine if a message needs urgent attention (NORMAL / HIGH RISK / CRISIS).
-🪄 Real-time recommendations (books, movies, songs) tailored to the user’s emotions—complete with icons and categories!
-🧸 A calming bear companion animation and beautiful chat interface.
-📊 On the therapist side, a dashboard shows all users, their latest messages, emotional tags, and a live trend graph showing risk scores and emotional progression.
- 🚩 If a CRISIS message is detected, the therapist is immediately alerted with a red card and call-to-action prompt.
How we built it
Frontend:
I built the frontend using React + Vite with calming, elegant UI inspired by mental health apps. We used:
-Lottie animations for mascots (like the bear!) -Framer Motion and CSS transitions for soothing effects -Chart.js for emotional trend graphs -Auth0 for authentication between User and Therapist views
Backend:
We used FastAPI and integrated:
-Gemini API (Google) for: -Emotion-related recommendations -Clustering emotional phrases -Risk scoring -Ollama (nomic-embed-text) for phrase embeddings -Custom emotion classifier using bhadresh-savani/distilbert-base-uncased-emotion -CSV logs per session with name, email, message, emotions, and risk score -Google crawler to enrich recommendation visuals (books, movies, music)
Architecture:
We kept the backend modular:
"/chat" handles conversation
"/predict" for emotion detection
"/crisis" for scoring
"/recommendations" for content
"/logs" for therapist access
Challenges we ran into
Emotion classification isn't always perfect—so we trained a fallback model and carefully tuned the prompts to be safer.
Frontend performance—with live recommendations and graph rendering, we had to optimize layout and rerenders.
Data formatting—making sure we stored emotions in a way that the chart could display them across multiple sessions was tricky.
Crisis detection—we had to be very sensitive with thresholds and responses so the system doesn’t either over- or under-alert therapists.
Accomplishments that we're proud of
We built a functioning full-stack application in under 48 hours with real AI features, not just mockups.
The therapist dashboard provides real emotional insight in a beautiful UI.
Crisis alerting works and is logged for traceability.
Our chatbot feels comforting, not robotic.
We pulled off agent-like behavior with Gemini's reasoning capabilities, summarizing emotional clusters and guiding therapists.
What we learned
How to use Gemini prompts for psychological reasoning and emotional clustering.
How to balance UX design with emotional sensitivity—users dealing with mental health issues need clarity, calm, and comfort.
Building agentic AI systems isn’t just about tech—it’s about giving meaning and insight to data.
We saw the power of multi-modal AI systems, where text, emotion, reasoning, and visualization come together to help real people.
What's next for SerenAI
Live crisis alerts on the therapist dashboard with a call button and real-time notifications.
Voice conversations so users can talk to SerenAI like a friend—and receive responses in audio using speech APIs.
Agentic explanations for therapists: Why is this emotion graph trending upward? SerenAI will soon explain the emotional clusters, changes, and risk progression with Gemini-powered summaries.
User history timeline, so therapists can see past sessions and mood swings over time.
Integration with licensed psychologists for hybrid human + AI intervention.
Log in or sign up for Devpost to join the conversation.