Here's the README.md for your NEET Rank Predictor project:
This project is a NEET Rank Predictor API built with FastAPI and machine learning models. It predicts a student's NEET rank based on various features like accuracy, time efficiency, difficulty average, and improvement rate. It also suggests eligible colleges based on predicted ranks using historical data and college cutoff ranks.
- FastAPI - For building the API.
- Scikit-learn - For training the machine learning model (Random Forest).
- Pandas & Numpy - For data manipulation and processing.
- Joblib - For saving and loading the trained model.
Follow these steps to get the project up and running locally.
Open your terminal/command prompt and run:
mkdir neet_rank_predictor
cd neet_rank_predictor
Create a virtual environment:
python -m venv venv
Activate it:
- Windows:
venv\Scripts\activate
- Mac/Linux:
source venv/bin/activate
Install the required dependencies using:
pip install -r requirements.txt
Create the following files and add the corresponding code/data:
main.py
- The FastAPI backend file.neet_historical_results.csv
- Dataset with historical NEET data for training the model.neet_college_cutoffs.csv
- College cutoff ranks for various colleges.requirements.txt
- List of all dependencies.
Start the server with the following command:
uvicorn main:app --host 0.0.0.0 --port 8000 --reload
Once the server is running, you should see output like:
INFO: Uvicorn running on http://127.0.0.1:8000
To predict a NEET rank based on input features:
curl -X 'POST' 'http://127.0.0.1:8000/predict-rank' \
-H 'Content-Type: application/json' \
-d '{"accuracy": 85.5, "time_efficiency": 78.2, "difficulty_avg": 3.5, "improvement_rate": 4.2}'
Response Example:
{
"predicted_rank": 12000
}
To get a list of colleges based on the predicted rank:
curl -X 'GET' 'http://127.0.0.1:8000/predict-college/12000'
Response Example:
{
"eligible_colleges": ["AIIMS Delhi", "JIPMER Puducherry", "KMC Manipal"]
}
Go to http://127.0.0.1:8000/docs to interact with the API using Swagger UI.
Your project folder should look like this:
neet_rank_predictor/
│── venv/ # Virtual environment (optional)
│── main.py # FastAPI backend
│── neet_historical_results.csv # Training dataset
│── neet_college_cutoffs.csv # College cutoff ranks
│── neet_rank_model.pkl # Saved ML model
│── requirements.txt # Dependencies
The model is trained using the historical NEET data (neet_historical_results.csv
). The main.py
file loads this data, selects the relevant features, and trains a Random Forest model to predict the NEET rank.
To deploy your API, you can use one of the following platforms:
- Railway.app / Render.com (for free hosting)
- Docker (for containerization)
- AWS / Google Cloud (for advanced hosting)
- FastAPI backend with a machine learning model for NEET rank prediction.
- API to predict rank and suggest eligible colleges based on NEET rank.
- Swagger UI documentation for easy interaction with the API.
Let me know if you need any additional features or clarifications! 😊