🚀 Mood2Mic: Real-Time Mood-to-Rap Playlist Generator 🎧
💡 Inspiration
Music is one of the most powerful emotional outlets — but most recommendation systems are algorithmically shallow. I wanted to create something that could understand human emotion from raw text (like a tweet or rant), and use that to curate a real-time rap playlist that matches your mood. Think of it as an emotional translator that speaks fluent hip-hop.
Inspired by:
- Everyday mood tweets and rants
- My love for discovering underrated rap artists
- The idea of combining NLP + music discovery in one clean interface
🛠 How I Built It
🧠 Emotion Detection
I fine-tuned cardiffnlp/twitter-roberta-base-emotion to work on rap lyrics in order to be more optimized for this project.
🔍 Real-Time Music Discovery
I send the detected emotion to Perplexity.ai with a custom-crafted prompt, asking for rap songs that fit that mood. This gave back diverse, high-quality track suggestions across YouTube, Spotify, and Apple Music.
🎤 Playlist Construction
The result is formatted into a clean, lightweight frontend where you can:
- Type your mood like a tweet
- See the detected emotion + confidence
- Instantly get matching rap songs with links
⚙️ Tech Stack
- FastAPI (backend API + emotion prediction)
- HuggingFace Transformers https://huggingface.co/bk-0704/mood2mic-emotion-model
- Perplexity.ai (music discovery)
- HTML/CSS/JS (Spotify-themed frontend)
- DigitalOcean VPS (24/7 deployment)
🌱 What I Learned
- How to fine-tune HuggingFace models and deploy them efficiently
- Building a full-stack ML app that connects NLP + real-world creativity
- How to serve static frontend assets and APIs together with FastAPI
🧩 Challenges I Faced
- DEPLOYEMENT WAS THE BIGGEST HEADACHE - Each service that i used kept having problems, digital ocean was the first one that works
✨ What's Next
- Add Spotify/Apple Music login → generate full playlists from your own music library
- Rap lyrics generation based on your mood
- Collaborative mood-based playlists
Built with 💚 and 🔊 for hackers, listeners, and mood chasers everywhere.
(Note the domain url is not setup but it will work soon)
Built With
- digitalocean
- fastapi
- github-codespaces
- huggingface
- natural-language-processing
- perplexity
- python
Log in or sign up for Devpost to join the conversation.