Skip to main content
This guide will walk you through the installation process for DeenPAL, from setting up your environment to verifying the installation.

System Requirements

Before you begin, ensure your system meets these requirements:
  • Python: Version 3.10 or higher
  • Conda: Anaconda or Miniconda for environment management
  • Storage: At least 2GB free space for dependencies and models
  • Internet: Required for downloading dependencies and embedding models
DeenPAL uses the sentence-transformers/all-MiniLM-L6-v2 embedding model, which will be downloaded automatically on first run.

Installation Steps

1

Clone the Repository

First, clone the DeenPAL repository from GitHub:
git clone https://github.com/Raza-Aziz/DeenPAL-RAG-based-Islamic-Hadith-Chatbot.git
cd DeenPAL-RAG-based-Islamic-Hadith-Chatbot
2

Create Conda Environment

Create a new conda environment with Python 3.10:
conda create -n deen-pal python=3.10 -y
This creates an isolated environment named deen-pal to avoid conflicts with other Python projects.
3

Activate Environment

Activate the newly created environment:
conda activate deen-pal
You’ll need to activate this environment each time you work with DeenPAL.
4

Install Dependencies

Install all required dependencies from the colab_requirements.txt file:
pip install -r colab_requirements.txt
The uv package manager is faster than standard pip. The project author recommends using it for improved installation speed.

Installed Dependencies

The installation includes the following key packages:
  • langchain - Core LangChain framework
  • langchain_community - Community integrations
  • langchain-huggingface - HuggingFace embeddings integration
  • langchain-openai - OpenAI/OpenRouter LLM integration
  • langchain-chroma - ChromaDB vector store integration
  • pypdf - PDF document loading
  • chromadb - Vector database for embeddings
  • streamlit - Web interface framework
  • huggingface-hub - HuggingFace model downloads
  • sentence-transformers - Embedding models
  • python-dotenv - Environment variable management

Verifying Installation

To verify that all dependencies are correctly installed, run:
python -c "import streamlit, langchain, chromadb; print('Installation successful!')"
If this command runs without errors, your installation is complete.
If you encounter any import errors, try reinstalling the specific package:
pip install --force-reinstall <package-name>

Next Steps

Now that DeenPAL is installed, you can:
  1. Prepare your Hadith data
  2. Configure your API keys
  3. Run the chatbot

Troubleshooting

Conda Not Found

If you don’t have Conda installed, download and install it from:

Package Installation Fails

If package installation fails:
  1. Ensure you have the latest pip: pip install --upgrade pip
  2. Try installing packages individually to identify the problematic one
  3. Check your internet connection

Python Version Issues

If you need a different Python version, create the environment with:
conda create -n deen-pal python=3.10.0 -y

Build docs developers (and LLMs) love