Skip to content

moksha-hub/GenAI-Task-Build-an-SHL-Assessment-Recommendation-System

Repository files navigation

SHL Assessment Recommendation System

This project implements an AI-powered recommendation system for SHL assessments. It uses a Two-Stage RAG Pipeline (Sentence-Transformers + Cross-Encoders) to retrieve relevant assessments based on natural language job descriptions.

📂 Project Structure

  • main.py: The unified entry point.
    • Validates the model on Train-Set (calculates Recall@10, MRR).
    • Generates predictions for Test-Set.
  • huggingface/app.py: A Gradio/FastAPI web server exposing a JSON API.
  • data/shl_assessments.json: The complete catalog of 443 assessments (Merged Type 1 + Missing Solution Packages).
  • scraper/: Contains the scraping logic (shl_smart_scraper.py) used to build the dataset.

🚀 Setup

  1. Clone the repository:

    git clone https://github.com/moksha-hub/GenAI-Task-Build-an-SHL-Assessment-Recommendation-System.git
    cd GenAI-Task-Build-an-SHL-Assessment-Recommendation-System
  2. Install Dependencies:

    pip install -r huggingface/requirements.txt

🏃 Usage

1. Run Validation & Prediction

Execute the main script to reproduce validation metrics and generate test predictions:

python main.py

Outputs:

  • Mokshagna_K.csv: Training set metrics (Recall, Precision, MRR).
  • Mokshagna_K_Test_Predictions.csv: Top-10 predictions for the 9 Test-Set queries.

2. Run the API

Start the local API server:

python huggingface/app.py
  • GUI: Open http://localhost:7860 in your browser.
  • API Endpoint:
    • URL: http://localhost:7860/recommend
    • Method: GET
    • Param: query (e.g., ?query=java developer&max_results=5)
    • Response: JSON.

📊 Performance

  • Assessments Indexed: 443 (Complete coverage)
  • Mean Recall@10: ~0.37 (Optimized Baseline)
  • Approach: Hybrid Search (Dense Retrieval + Cross-Encoder Reranking) + Query Expansion.

👤 Author

Mokshagna K

About

SHL Recommendation engine for search Feasibility

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors