Views
No views yet
RAG/
├── CHROMA_DB/ # Vector database management
├── DATA_resume/ # Sample resumes
├── JOB_DESCRIPTIONS/ # Job description PDFs
├── KNOWLEDGE_EXTRACTOR/ # Document parsing
├── SLM_manager/ # AI augmentation
└── TEXT_EMBEDDING_MODEL/ # Text embedding generation1# Create and activate virtual environment
2python -m venv .venv
3source .venv/bin/activate # On Windows: .venv\Scripts\activate
4
5# Install dependencies
6pip install -r requirements.txtbrew install tesseractsudo apt-get install tesseract-ocrcurl https://ollama.ai/install.sh | shollama pull mistralollama run mistral "Hello, testing Mistral AI"1git clone https://github.com/deepanmpc/ResumeAnalyse_RAG-Architecture.git
2cd RAG1# Resume Analysis and Matching System 📄✨
2
3A sophisticated resume analysis and matching system that uses RAG (Retrieval Augmented Generation) to match resumes with job descriptions intelligently.
4
5## 🌟 Features
6
7- 📝 **Multi-Format Support**: Process resumes in PDF and Word formats.
8- 🔍 **Advanced Text Extraction**: OCR capabilities for scanned documents.
9- 🧠 **Intelligent Matching**: Uses embeddings and semantic search to find the best candidates.
10- 💾 **Vector Database**: ChromaDB for efficient similarity search and storage.
11- 🤖 **AI Enhancement**: Mistral AI for advanced analysis and summarization.
12- 📊 **Structured Output**: JSON format for analysis results.
13- 🖥️ **Interactive Web UI**: A React-based frontend for a user-friendly experience.
14
15## 🖥️ Web Frontend
16
17The project includes a modern and interactive web-based user interface built with React, TypeScript, and Vite.
18
19### Frontend Features
20
21- **Resume Matching Dashboard**: Upload a job description and see the top matching resumes.
22- **Detailed Match View**: For each matched resume, view details like:
23 - Resume file name.
24 - The section that matched best (e.g., "experience", "skills").
25 - A similarity score.
26 - The relevant text from the resume that matched the job description.
27- **AI Summary Display**: Shows an AI-generated summary of the top matches. It gracefully handles and displays errors if the summary generation fails (e.g., if the AI model is not available).
28- **User-Friendly Interface**: Built with modern UI components for a smooth experience.
29
30## 🚀 Getting Started
31
32### Prerequisites
33
34- Python 3.10 or higher
35- Node.js and npm (or yarn/pnpm)
36- Tesseract OCR (for scanned documents)
37- Ollama with Mistral AI model (for enhanced analysis)
38
39### Installation
40
411. **Clone the repository**:
42 ```bash
43 git clone <repository-url>
44 cd RAG
45 ```
46
472. **Backend Setup**:
48 ```bash
49 # Create and activate virtual environment
50 python -m venv .venv
51 source .venv/bin/activate # On Windows: .venv\Scripts\activate
52
53 # Install Python dependencies
54 pip install -r requirements.txt
55 ```
56
573. **Frontend Setup**:
58 ```bash
59 # Navigate to the web directory
60 cd web
61
62 # Install Node.js dependencies
63 npm install
64 ```
65
664. **Tesseract OCR** (Optional - for scanned documents):
67 - macOS: `brew install tesseract`
68 - Linux: `sudo apt-get install tesseract-ocr`
69 - Windows: Download installer from GitHub
70
715. **Mistral AI Setup** (Optional - for enhanced analysis):
72 - [Install Ollama](https://ollama.ai)
73 - Pull the Mistral model: `ollama pull mistral`
74
75## 🎯 Usage
76
77To run the application, you need to start both the backend server and the frontend development server.
78
791. **Start the Backend Server**:
80 From the project root directory (`RAG/`):
81 ```bash
82 uvicorn api:app --reload
83 ```
84 The API will be available at `http://127.0.0.1:8000`.
85
862. **Start the Frontend Server**:
87 In a new terminal, navigate to the `web/` directory:
88 ```bash
89 cd web
90 npm run dev
91 ```
92 The web application will be available at `http://localhost:5173` (or another port if 5173 is busy).
93
943. **Using the Application**:
95 - Open your browser to the frontend URL.
96 - Use the dashboard to upload a job description and see the matching resumes.
97
98### Command-Line Usage (Alternative)
99
100You can also use the system from the command line for indexing and matching.
101
1021. **Index Resumes**:
103 ```bash
104 python main.py --index DATA_resume/
105 ```
106
1072. **Match with Job Description**:
108 ```bash
109 python main.py --job JOB_DESCRIPTIONS/job.pdf -n 5
110 ```
111
112## 🔧 Components
113
114- **Backend**: FastAPI, ChromaDB, SentenceTransformers
115- **Frontend**: React, TypeScript, Vite, Tailwind CSS, shadcn/ui
116- **AI**: Ollama, Mistral
117
118---
119Built with ❤️ for making recruitment smarter
120pip install -r requirements.txtbrew install tesseractsudo apt-get install tesseract-ocrpython main.py --index DATA_resume/python main.py --job JOB_DESCRIPTIONS/job.pdf -n 5python main.py --query "python developer with 5 years experience" -n 31{
2 "rank": 1,
3 "id": "resume_123",
4 "filename": "candidate.pdf",
5 "similarity": 0.89,
6 "sections": {
7 "experience": 0.92,
8 "skills": 0.85,
9 "education": 0.78
10 }
11}