Introducing MindMyMood: Your Mood Companion Forever

Introducing MindMyMood: Your Mood Companion Forever

Introduction

In today's world, stress, anxiety, and depression are some of the most common mental health issues that people face. The Mind My Mind application was created to assist individuals in dealing with their moods. The application is powered by MindsDB and employs the OpenAI GPT-4 model to analyze user input and predict their mood. Based on their mood, the application offers two activities, two songs, and two food items that they can consume to feel better or cherish their good moments.

Creating MindsDB Models

MindsDB is an open-source AI framework that can be used to build and train machine learning models. To build the Mind My Mood application, a bunch of NLP models were created using MindsDB. These models used the OpenAI engine on a variety of prompts to identify mood patterns and provide selective suggestions based on them. By leveraging the power of MindsDB, the application can provide users with more accurate and personalized recommendations.

I trained 4 models for my application. This is how we created all of them.

Mood Detection Model Creation

CREATE MODEL openai_mood_model
PREDICT Mood
USING
engine = 'openai',
model_name = 'gpt-4',
prompt_template = 'Describe the human mood of the text
strictly as "HAPPY", "SAD", "ANGRY", "ANXIOUS", "EXCITED", "BORED", "FRUSTRATED", "DEPRESSED", "CONTENT", "ENTHUSIASTIC", 
"TENSE", "IRRITATED", "CONFUSED", "NOSTALGIC", "EMPATHETIC" or "APATHETIC".
"I am so happy to see you.":HAPPY
"I amm feeling sad today because my best friend moved away and I miss them so much.":SAD
"I am really angry right now because someone cut me off in traffic and almost caused an accident.":ANGRY
"{{text}}.":';

Mood-Based Activity Suggestion Model Creation

CREATE MODEL openai_mood_activity_model
PREDICT Activity
USING
    engine = 'openai',
    model_name = 'gpt-4',
    prompt_template = 'Suggest two activities that I can do when I am feeling mood. Return the activities and its benefit in 15 words as two. mood: {{mood}}';

Mood-Based Music Suggestion Model Creation

CREATE MODEL openai_mood_music_model
PREDICT Song
USING
    engine = 'openai',
    model_name = 'gpt-4',
    prompt_template = 'Suggest two songs that I can listen to when I am feeling mood. Return the song and its Youtube link in 2 lines. mood: {{mood}}';

Model-Based Food Suggestion Model Creation

CREATE MODEL openai_mood_food_model
PREDICT Food
USING
    engine = 'openai',
    model_name = 'gpt-4',
    prompt_template = 'Suggest two food items and that I can eat when I am feeling mood. Return the food item and its benefit in about 15 words. mood: {{mood}}';

Preparing The Application

To create the Mind My Mind application, a Node Express server was set up to handle user requests and communicate with the MindsDB models. The client-server architecture ensures that the application is scalable and can handle a large number of requests simultaneously. It also allows for the separation of concerns between the client-side and server-side logic.

Application Details

The Mind My Mind application begins by prompting the user to enter a sentence that describes their mood. The underlying OpenAI GPT-4 model then analyses the user input and predicts their mood. Based on their mood, the application offers two activities, two songs, and two food items that they can consume to feel better or cherish their good moments. The recommendations are personalized based on the user's mood, and they can choose to engage in any of the suggested activities, listen to the recommended songs, or try the suggested food items.

Future Scopes

The Mind My Mind application has the potential for significant growth in the future. More AI-powered options can be added to help people deal with various shades of mood. For instance, adding a feature that allows users to log their mood daily and provide personalized recommendations based on their mood history. The application can also incorporate natural language processing (NLP) to provide personalized therapy and counselling to users.

App Gallery

The app is deployed and is available to everyone and the GitHub repository is shared as well. Meanwhile, feel free to check some screenshots of the working App.

App Deployment: https://mindmymood.club/

GitHub Repository: MindMyMood

App Landing Page

App Loading Screen

App Mood Detection

Mood-Based Activity Suggestion

Mood-Based Music Suggestion

Mood-Based Food Suggestion

Error Alert when Mood has not been Detected First

Conclusion

The Mind My Mind application is revolutionary for improving mental health and well-being. The application is powered by MindsDB and OpenAI GPT-4 and provides personalized recommendations based on user mood. It has the potential to help individuals deal with various shades of mood and improve their overall quality of life. The application is available for download on the App Store and Google Play, and we encourage everyone to give it a try.