This GitHub repository contains the companion code for SouLLMate V1 from the paper "SouLLMate: An Application Enhancing Diverse Mental Health Support with Adaptive LLMs, Prompt Engineering, and RAG Techniques". The project has been upgraded to SouLLMate v3 (Visual Large Language Model), and the code will be released in the future.
During the testing of SouLLMate, we collected proprietary data. Detailed data introduction and content will be placed in the Data folder. If you use our collected data or mention the SouLLMate paper, please cite:
@article{guo2024soullmate,
title={SouLLMate: An Application Enhancing Diverse Mental Health Support with Adaptive LLMs, Prompt Engineering, and RAG Techniques},
author={Guo, Qiming and Tang, Jinwen and Sun, Wenbo and Tang, Haoteng and Shang, Yi and Wang, Wenlu},
journal={arXiv preprint arXiv:2410.16322},
year={2024}
}SouLLMate is an advanced AI-powered platform designed to provide comprehensive psychiatric assistance. It offers personalized mental health support through various features including interactive conversations, assessments, and learning resources.
- Personalized interaction with AI
- Comprehensive mental health assessments
- Progress tracking and reporting
- Adaptive learning and goal setting
- Educational resources on mental health
- Profile management
- RAG (Retrieval-Augmented Generation) capabilities
- Anaconda or Miniconda
- Python 3.12
- Clone the repository:
conda env create -f environment.yml- Activate the environment:
conda activate chatbot-
Set up your OpenAI API key:
- Open the
Configclass in the main script. - Replace
"Your Api Key"with your actual OpenAI API key.
- Open the
-
Ensure you have the necessary folders:
- Create a folder named
Rag_documentin the project directory for RAG functionality.
- Create a folder named
-
Make sure you're in the project directory and your conda environment is activated.
-
Run the main script:
python main.py- Open a web browser and navigate to
http://localhost:5006to access the SouLLMate interface.
- Register an account or log in to an existing one.
- Navigate through different tabs to access various features:
- Interactive Chat and Advisory
- Pre-Assessment
- Learn Psychology
- Practice Psych
- Suicide Risk Detection
- Report Generation
- RAG (Retrieval-Augmented Generation)
- And more...
UserManager: Handles user registration, login, and profile management.PDFProcessor: Processes various document formats including PDFs.LangchainManager: Manages language model interactions and generates responses.SuicideDetector: Analyzes text for potential suicide risk.ReportGenerator: Creates comprehensive reports based on user data.RAGManager: Implements Retrieval-Augmented Generation for enhanced responses.UIManager: Manages the user interface and interactions.
This application is for educational and demonstration purposes only. It is not a substitute for professional medical advice, diagnosis, or treatment.
[GPL-3.0 license: https://github.com/QM378/SouLLMate/blob/main/LICENSE]
For support or inquiries, please contact [guoqm07@gmail.com, tangjw91@gmail.com].
This project uses various open-source libraries and AI models. We thank the developers and contributors of these technologies for their work.
Contributions to SouLLMate are welcome. Please feel free to submit pull requests or open issues to improve the functionality or documentation of the project.