Giter VIP home page Giter VIP logo

virtual-psychiatrist's Introduction

Virtual-Psychiatrist


Introduction

The use of artificial intelligence (AI) in healthcare has revolutionized the provision of mental health support in recent years. Natural language processing (NLP)-based chatbots have become powerful tools for offering timely support. This study looks on the development, application, and evaluation of a GPT-2-focused chatbot that was created with psychological considerations in mind. With the help of a wealth of textual data from Hugging Face and other websites, the chatbot can effectively handle user requests because it has been trained on a wide range of contextually appropriate content. The methodical approach covered in this article comprises approaches for data extraction, cleaning, visualization, training, and assessment. A portion of this procedure is evaluating language coherence and semantic understanding using metrics like as DistilBERT Cosine Similarity. Additionally, the integration of FastAPI for backend services, MongoDB for data storage, and ReactJS for front-end development ensures user-friendly interfaces, accessible communication, and efficient data management. These elements improve efficacy and transparency in the mental health services sector. The chatbot's name is "Harmony". Its purview encompasses offering coping strategies, counseling for stress, anxiety, and depression, and serving as a point of contact for mental health and emergency support. Traditional therapy is improved by continuing to monitor and support the patient.


Technologies Used

  1. Front-end
    • React.js: A JavaScript library for building user interfaces.
    • Tailwind CSS: It is a class with all the CSS properties written in a different way which can directly be used with simple shorthand.
    • Particle.js: A lightweight JavaScript library for creating interactive particle animations on a webpage.
  2. Back-end
    • Fast API: An efficient framework for building python APIs. It is much faster than any other python framework like Flask and Django. Fast API provides the flexibility of building large applications with high performance.
  3. Machine-Learning
    • PyTorch: A free and open-source library for machine learning and deep learning with more advanced built-in libraries to be utilized directly to ease the task of machine learning.
    • Transformers: The Transformers library enables developers to create sophisticated natural language processing (NLP) applications with minimal effort with pre-defined architecture.
  4. Database Technologies
    • MongoDB: A powerful NoSQL database system that efficiently stores unstructured data.
    • MongoDB Engine (MongoEngine): A Python Object-Document Mapper (ODM) library for MongoDB, facilitating interaction with MongoDB databases in Python applications.
  5. Deployment Technologies
    • Atlas: MongoDB Atlas is a MongoDB-created, managed, multi-cloud database service that simplifies deployment, management, and scaling, enabling developers to build resilient, high-performance applications across various cloud providers.
    • AWS EC2: Resizable, secure compute capacity is made possible by AWS EC2, which is perfect for implementing applications with scalable, on-demand infrastructure.

Methodologies

  1. Literature Review

    • Transformers and Large Language Models
    • PyTorch
    • GPT (Generative Pre-trained Transformers):
    • Text Generation
  2. Data Preprocessing

    • Named Entity Removal
    • Text Translation from Chinese (SMILE Dataset) to English
    • Enhance the Beginning of the Conversation with Greetings
    • Merge Under Specific Format
  3. Data Exploration and Visualization

    • Unigrams and Bigrams

      Unigram and Bigrams

    • Word Cloud

      Word Cloud

    • Latent Dirichlet Allocation (LDA)

      Latent Dirichlet Allocation

    • Intent Classification

      Intent Classification

  4. Methods Used

    • Tokenization
    • Model Training
    • Model Evaluation and Testing
      • BLEU Score
      • ROUGE Score
      • DistilBERT Cosine Similarity Score

Result

  1. Landing Page Harmony Landing Page
  2. Sign Up Page Harmony Sign Up Page
  3. Login Page Harmony Login Page
  4. Chat History Harmony Chat History Page
  5. Chat Screen and Conversation Harmony Chat Conversation Page
  6. Evaluation Results
    • Evaluation Metrics: Comparing responses from ChatGPT-4 and the proposed model.
      Intent BLUE ROUGE Cosine Similarity
      Stress 0.013695 0.173437 0.651334
      Anxity 0.017301 0.171054 0.611296
      Depression 0.011467 0.160048 0.601141
      Greeting 0.018578 0.096368 0.479845
      Social Anxity 0.009661 0.119167 0.596898
      Others 0.013368 0.154787 0.507061
    • Average Score of Evaluation Metrics Average Score of Evaluation Metrics

References

virtual-psychiatrist's People

Contributors

chauhanmahavir avatar trushna-39 avatar krinapatel1211 avatar makwanadev avatar nikitamaru avatar

Stargazers

 avatar

Watchers

 avatar  avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.