MoodMate Study is a Flutter-based mobile app that helps students study smarter by understanding how they feel. It detects the user's mood from text input, recommends music that matches that mood, and pairs it with a built-in focus timer and analytics dashboard — all in one place.
The idea is simple: your emotional state affects how well you focus. MoodMate Study bridges the gap between how you feel and how you study, by combining mood detection, mood-based music, and productivity tracking into a single, seamless experience.
Users can type how they're feeling in natural language, and the app analyzes the text using a pre-trained emotion classification model (via the Hugging Face Inference API) to detect emotions like joy, sadness, anger, fear, and more.
Based on the detected mood, the app fetches and recommends music tracks using the Jamendo API — a royalty-free music platform. Users can also search for songs by name, artist, or album. Playback is handled in-app using the audioplayers package.
A built-in Pomodoro-style focus timer helps users stay on track during study sessions. Session data (duration, completion status) is saved locally for later review.
Visualizes mood trends and study session history over time, giving users insight into how their mood correlates with their productivity.
All user data — mood logs, session history, and preferences — is stored locally on-device using SQFlite, so the app works reliably without needing constant internet access (except for API calls to fetch mood analysis and music).
The app is built following Clean Architecture principles, separating concerns into distinct layers for better scalability, testability, and maintainability.
lib/
├── data/
│ ├── controllers/ # Business logic controllers
│ ├── models/ # Data models (e.g., Song, Mood)
│ └── repositories/ # Data layer — talks to services & local DB
├── presentation/
│ ├── providers/ # State management (Provider)
│ └── screens/ # UI screens
├── services/ # External API integrations (Jamendo, Hugging Face)
└── main.dart
State Management: Provider Local Database: SQFlite External APIs: Hugging Face Inference API (mood detection), Jamendo API (music)
| Category | Technology |
|---|---|
| Framework | Flutter / Dart |
| State Management | Provider |
| Local Database | SQFlite |
| Mood Detection API | Hugging Face Inference API |
| Music API | Jamendo API |
| Audio Playback | audioplayers |
| HTTP Client | http |
| Environment Config | flutter_dotenv |
- Home Screen — Overview and quick navigation
- Mood Detection Screen — Input text and get mood analysis
- Music Recommendation Screen — Mood-based song suggestions with search
- Focus Timer Screen — Start, pause, and track study sessions
- Analytics Screen — Charts and trends for mood + study data
- Profile Screen — User preferences and settings
- Flutter SDK installed
- A code editor (VS Code / Android Studio)
- A Hugging Face API token — get one here
- A Jamendo Client ID — get one here
-
Clone the repository
git clone https://github.com/Amanshrivastab/moodmate_study.git cd moodmate_study -
Install dependencies
flutter pub get
-
Set up environment variables
Create a
project.envfile in the project root (refer toproject.env.examplefor the required format):JAMENDO_CLIENT_ID=your_jamendo_client_id_here HUGGINGFACE_API_TOKEN=your_huggingface_api_token_here⚠️ Never commit your realproject.envfile. It's already excluded via.gitignore. -
Run the app
flutter run
| Variable | Description |
|---|---|
JAMENDO_CLIENT_ID |
Client ID for accessing the Jamendo music API |
HUGGINGFACE_API_TOKEN |
Access token for calling the Hugging Face Inference API (mood detection model) |
MoodMate Study was originally built as a B.Tech final year project and is actively being improved — including additional analytics features, UI polish, and refined mood-detection accuracy.
This is currently a solo learning project, but suggestions and feedback are always welcome via Issues or Pull Requests.
This project is open for learning and educational purposes.