Moodify
Moodify: Recognizes emotion from face, generates a suitable playlist in the music player
Install / Use
/learn @ajayns/MoodifyREADME
Moodify
(No longer maintained)
A WebApp which uses a snapshot taken of the user to detect emotion and using this, generate a suitable music playlist. This project was built for ACM Month Of Code, actual coding done in about 3 weeks.
Read the detailed article on building Moodify here: https://medium.com/@ajay.ns08/acm-month-of-code-2k17-building-moodify-d5d9e0c52ca7
Implementation
The Cam, Music Player, scripts for emotion recognition and Database were wired and wrapped up into a WebApp using Flask, using routes to use the Backend like an API while the frontend handles the user.
Being an experimental setup built in such a short span of time, the user interface and flow would require multiple fixes before deployment.
Installation
You should have the following preinstalled:
- OpenCV
- MongoDB
- dlib Predictor data files to be placed in data/
- Haar Cascades data files to be placed in data/
- Python 2
- files/mp3 and files/img store the music data and album art
Preferably setup a Virtual Env and then you'll just need to install packages:
pip install -r requirements.txt
Make sure you have MongoDB running to host the database. Also run a simple http server to serve the files/ folder at localhost:8000
cd files
python -m SimpleHTTPServer
Start the program
python app.py
Open the webapp from browser at localhost:5000
Technologies
Frontend
- AngularJS : JavaScript framework for programming the music player.
- Materialize : CSS Framework for skinning the app based on Google's Material Design.
- WebcamJS : JavaScript library for Image Capture
- Angular SoundManager 2 : Adds music player functionality for AngularJS using SoundManager 2 API
Backend
- Flask : A microframework for Python for Web App building
- OpenCV : Open source Computer Vision, used here for facial recognition, analysis and emotion identification.
- A few machine learning libraries used along with OpenCV such as dlib, NumPy, scikit
Individual Components
- ng-musicplayer : The music player component built on AngularJS and Materialize.
- PyEmotionRecognition : The script used to detect the mood from an image using OpenCV and machine learning libraries.
- PyMusicMood : For automatic classification of music into moods based on parameters extracted from Spotify API.
- Cam-App, Py-Flask-Wa : Initial code in setting up the Cam and Flask Server
Related Skills
claude-opus-4-5-migration
107.2kMigrate prompts and code from Claude Sonnet 4.0, Sonnet 4.5, or Opus 4.1 to Opus 4.5
model-usage
346.4kUse CodexBar CLI local cost usage to summarize per-model usage for Codex or Claude, including the current (most recent) model or a full model breakdown. Trigger when asked for model-level usage/cost data from codexbar, or when you need a scriptable per-model summary from codexbar cost JSON.
TrendRadar
50.7k⭐AI-driven public opinion & trend monitor with multi-platform aggregation, RSS, and smart alerts.🎯 告别信息过载,你的 AI 舆情监控助手与热点筛选工具!聚合多平台热点 + RSS 订阅,支持关键词精准筛选。AI 智能筛选新闻 + AI 翻译 + AI 分析简报直推手机,也支持接入 MCP 架构,赋能 AI 自然语言对话分析、情感洞察与趋势预测等。支持 Docker ,数据本地/云端自持。集成微信/飞书/钉钉/Telegram/邮件/ntfy/bark/slack 等渠道智能推送。
mcp-for-beginners
15.8kThis open-source curriculum introduces the fundamentals of Model Context Protocol (MCP) through real-world, cross-language examples in .NET, Java, TypeScript, JavaScript, Rust and Python. Designed for developers, it focuses on practical techniques for building modular, scalable, and secure AI workflows from session setup to service orchestration.
