This is a submission for the Hacktoberfest Weekend Challenge: Build for a Friend
What I Built
I built SlumberSafe, a voice-first, AI-led bedside companion designed for a close friend who struggles with late-night anxiety and "doomscrolling" before bed.
Whenever they try to sleep, their brain starts reminding them of unfinished tasks, emails they forgot to send, and worries about tomorrow. SlumberSafe solves this by acting as a calm, empathetic listener. You simply lie in bed, tap "Start Wind-Down", and dictate your worries. The AI listens, naturally responds with comforting reassurance, and quietly extracts any actionable tasks you mention, safely "parking" them in a MongoDB database for the next morning. Finally, it gently guides you to sleep with a whispered bedtime story.
Demo
Code
π SlumberSafe: Bedside Debrief & Doomscroll Deterrent
Built for Hacktoberfest 2026 (#hf26challenge) β DEV Challenge #1: "Build for a Friend"
A private, voice-first bedtime decompression companion designed to break the late-night racing thoughts and doomscrolling cycle.
π The Story & Problem Statement
Late at night around 11:00 PM, unfinished to-dos, racing thoughts, and tomorrow's stresses create bedtime friction. To cope with bedtime anxiety, many people turn to blue light feeds and social media, doomscrolling past 1:00 or 2:00 AM.
Commercial AI chatbots fail at this use case:
- They require staring into bright text chat UIs.
- They do not automatically lock away to-dos for the next morning.
- They log intimate vulnerable thoughts onto closed commercial cloud servers.
SlumberSafe solves this with an OLED screen-free voice companion powered by open-weight AI (Meta's Llama 3.3 via Groq) and soft whispered bedside audio (ElevenLabs).
β¨ Features (MVP Scope)
-
Late-Night Doomscroll Interceptor Banner
- Active bedtimeβ¦
How I Built It
I wanted SlumberSafe to be lightning fast and completely hands-free. To achieve this, I built the app using Next.js 14 (App Router) and relied heavily on open-weight AI models.
json
{
"assistant_response": "1-2 warm conversational sentences.",
"tasks": [{"text": "Finish the report tomorrow morning", "priority": "normal"}],
"next_question": "A short natural follow-up question.",
"session_complete": false,
"should_offer_story": false
}
the Llama 3.3 70B open-weight model via the Groq SDK. Llama 3.3 is incredibly fast and capable of deep empathy and structured JSON extraction in a single pass.
I engineered a prompt that forces the LLM to output a strict JSON schema on every conversational turn:
This allows the backend to automatically map the extracted tasks into MongoDB Atlas, while streaming the assistant_response back to the frontend to be spoken aloud using the native Web Speech API (webkitSpeechRecognition) and ElevenLabs for realistic whispered TTS.
The frontend implements a strict state machine (LISTENING β PROCESSING β AI_SPEAKING) to prevent the microphone from picking up the AI's own voice and creating an echo loop.
Why Does Open Innovation Matter?
Open innovation made this project possible by providing access to world-class, open-weight models like Llama 3.3. If I had to rely on a slow, closed API, the conversational latency would ruin the relaxing, bedside experience. Because Llama is open and hosted on ultra-fast inference hardware like Groq, the responses feel instantaneous and natural. Open innovation also allows us to run these powerful models locally or on edge devices in the future, meaning sensitive, late-night personal thoughts wouldn't even need to leave the user's bedroom network.
Prize Categories
Best Use of Open-Weight AI: For leveraging Llama 3.3 to handle empathy and data extraction simultaneously.
Accessibility & UX: For building a completely hands-free, dark-themed voice interface designed for tired eyes.
Top comments (0)