HR Assistant - RAG Based Application

This project is a Retrieval-Augmented Generation (RAG) application designed to assist HR departments. It allows users to upload HR-related documents (like policy PDFs or employee handbooks) and query them using an LLM (Large Language Model) to get accurate, context-aware answers.

Features

  • Document Ingestion: Upload and process PDF documents.
  • Vector Storage: Uses FAISS or ChromaDB for efficient similarity search.
  • RAG Pipeline: Combines retrieved document context with LLM generation for precise answers.
  • User Interface: Built with Streamlit for an interactive experience.

Tech Stack

  • Language: Python
  • Framework: LangChain
  • LLM: OpenAI (GPT-3.5/4) or Groq (Llama3)
  • Frontend: Streamlit
  • Embeddings: HuggingFace / OpenAI Embeddings

Prerequisites

Ensure you have the following installed:

  • Python 3.10 or higher
  • An API Key (OpenAI or Groq)

Installation & Setup

  1. Clone the repository:

    git clone https://github.com/vinaygandhigit/HRAssistantRAG.git
    cd HRAssistantRAG
  2. Create a virtual environment:

    python -m venv venv
    source venv/bin/activate  # On Windows: venvScriptsactivate
  3. Install dependencies:

    pip install -r requirements.txt
  4. Set up Environment Variables:
    Create a .env file in the root directory and add your keys:

    OPENAI_API_KEY=your_api_key_here
    GROQ_API_KEY=your_groq_key_here

How to Run

Run the Streamlit application using the following command:

streamlit run app.py

Usage

  1. Open the local URL provided by Streamlit.
  2. Upload your HR PDF documents via the sidebar.
  3. Wait for the documents to be indexed.
  4. Ask questions like "What is the company's remote work policy?" or "How many paid leaves are allowed?"