Skip to content

Web application that detects emotions from faces in photos or webcam streams and generates personalized recommendations using OpenAI’s ChatGPT API. Provides emotion statistics, music suggestions, activity ideas, and daily emotional summaries.

Notifications You must be signed in to change notification settings

nolancacheux/gpt-emotion-analyzer

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

22 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

GPT-Emotion Analyzer

App Screenshot 1
Analyze emotions from photos and get personalized AI-driven recommendations.

About The Project

GPT-Emotion Analyzer is a web application that detects emotions from faces in photos and generates personalized recommendations based on the detected feelings. Users can upload images or capture photos directly from their webcam. The application uses an AI model for face and emotion detection and then communicates with OpenAI's ChatGPT API (gpt-3.5-turbo) to provide tailored suggestions, such as opinion pieces, music recommendations, or activities suited to the user's emotional state.

Key Features

  • Face & Emotion Detection: Analyzes emotions from uploaded images or live webcam feed.
  • AI-Powered Recommendations: Integrates with the ChatGPT API to generate personalized content.
  • Emotion Statistics: Displays a breakdown of detected emotions with progress bars.
  • Daily Analysis: Provides a personalized daily summary based on the user's emotions.
  • Custom Suggestions: Offers music, activities, and other ideas tailored to your mood.

Built With


Getting Started

Follow these instructions to set up and run the project locally.

Prerequisites

Installation

  1. Clone the repository:

    git clone https://github.com/nolancacheux/gpt-emotion-analyzer.git
    cd gpt-emotion-analyzer
  2. Install client dependencies:

    cd client
    npm install
  3. Install server dependencies:

    cd ../server
    npm install
  4. Set up your environment variables: Create a .env file in the server directory and add your OpenAI API key:

    OPENAI_API_KEY="your_openai_api_key_here"

Running the Application

  1. Start the backend server: From the server directory, run:

    npm run server
  2. Start the frontend client: In a separate terminal, from the client directory, run:

    npm run dev
  3. Open the application: Open your browser and navigate to http://localhost:5173. You can now upload an image or use your webcam to start analyzing emotions!


Contributing

Contributions are what make the open-source community such an amazing place to learn, inspire, and create. Any contributions you make are greatly appreciated.

If you have a suggestion that would make this better, please fork the repo and create a pull request. You can also simply open an issue with the tag "enhancement".

  1. Fork the Project
  2. Create your Feature Branch (git checkout -b feature/AmazingFeature)
  3. Commit your Changes (git commit -m 'Add some AmazingFeature')
  4. Push to the Branch (git push origin feature/AmazingFeature)
  5. Open a Pull Request

Don't forget to give the project a star! Thanks again!

License

Distributed under the ISC License. See LICENSE for more information.

Contact

Nolan Cacheux - @nolancacheux

Project Link: https://github.com/nolancacheux/gpt-emotion-analyzer

Screenshots

Explication 2 Explication 3 Explication 4 Explication 5

About

Web application that detects emotions from faces in photos or webcam streams and generates personalized recommendations using OpenAI’s ChatGPT API. Provides emotion statistics, music suggestions, activity ideas, and daily emotional summaries.

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published