Anveshak Neo is an AI-powered chatbot that detects emotions from text input. It provides real-time emotional analysis using a trained model, allowing users to engage in meaningful conversations. The chatbot stores past conversations in a PostgreSQL database using SQLAlchemy ORM, enabling users to revisit and continue previous chats.
- Emotion Detection: Analyzes text input to determine the user's emotional state.
- Chat History Management: Stores past conversations in a PostgreSQL database.
- User-Friendly Interface: Built with Streamlit for a seamless chat experience.
- Multi-Session Support: Allows users to navigate between different chat sessions.
- AI-Powered Responses: Utilizes an LLM model to generate intelligent replies.
- Delete Chat Option: Users can remove unwanted chat sessions.
- Frontend: Streamlit
- Backend: Python, SQLAlchemy ORM
- Database: PostgreSQL
- AI Model: LLM - Gemini
Anveshak Neo is trained on the Emotion Raw Dataset, which contains labeled emotion data for accurate sentiment analysis.
- Clone the repository:
git clone https://github.com/PythonicVarun/Anveshak-Neo.git cd Anveshak-Neo - Create a virtual environment and activate it:
python -m venv venv source venv/bin/activate # On Windows use `venv\Scripts\activate`
- Install dependencies:
pip install -r requirements.txt
- Set up the PostgreSQL database and update the
.envconfiguration. - Run the chatbot:
python run.py
To run Anveshak Neo using Docker, follow these steps:
- Ensure you have Docker installed on your system.
- Build and start the services using Docker Compose:
docker-compose up --build
- The PostgreSQL database and chatbot service will start automatically.
- Access the chatbot at
http://localhost:8501/.
Create a .env file based on .env.example and update the required credentials:
# Database Configuration
POSTGRES_USER=your_postgres_user
POSTGRES_PASSWORD=your_postgres_password
POSTGRES_DB=your_postgres_db_name
# API Key for Gemini
GEMINI_API_KEY=your_gemini_api_key
# Database URL
DATABASE_URL=postgresql://your_postgres_user:your_postgres_password@localhost:5432/your_postgres_db_name
# Logging
LOG_LEVEL=DEBUG
- Click "Start New Chat" in the sidebar to begin a fresh conversation.
- A new chat session is created and stored in the database.
- Previous chats are displayed in the sidebar.
- Click on any chat title to continue a past conversation.
- Type your message in the input box and press enter.
- Anveshak Neo will analyze and respond with an emotion-based reply.
- Click the ❌ button next to a chat title in the sidebar to delete it.
Anveshak-Neo/
├── .env.example
├── LICENSE
├── README.md
├── docker-compose.yml
├── models/
│ ├── dataset/
│ │ └── emotion_dataset_raw.csv
│ └── text_emotion.pkl
├── requirements-dev.txt
├── requirements.txt
├── results/
├── run.py
├── src/
│ ├── __init__.py
│ ├── app/
│ │ ├── __init__.py
│ │ ├── core/
│ │ │ ├── emotions.py
│ │ │ └── llm_response.py
│ │ ├── database/
│ │ │ └── db.py
│ │ ├── main.py
│ │ └── stylesheets/
│ │ └── styles.css
├── train-v2.py
└── train.py
- Implement voice input and output.
- Add support for multiple languages.
- Improve emotion detection with deep learning models.
- Integrate with external APIs for enhanced chatbot capabilities.
Contributions are welcome! Feel free to submit a pull request or open an issue.
See the BSD 3-Clause License for more details.
This project needs a star️ from you. Don't forget to leave a star✨
Follow my Github for content