A robust recommendation system with a modern web interface built using Python and Flask.
- Content-based recommendation system using TF-IDF and cosine similarity
- Modern and responsive web interface
- Easy-to-use API endpoints
- Support for custom datasets
- Real-time recommendations
- Python 3.12 or higher
- pip (Python package installer)
- Clone the repository:
git clone <repository-url>
cd Recommendations_System- Create a virtual environment (recommended):
python -m venv venv
# On Windows:
venv\Scripts\activate
# On Unix or MacOS:
source venv/bin/activate- Upgrade pip to the latest version:
python -m pip install --upgrade pip- Install the required packages:
pip install -r requirements.txtIf you encounter any installation issues, you can try installing packages one by one:
pip install numpy
pip install pandas
pip install scikit-learn
pip install flask
pip install flask-wtf
pip install python-dotenv
pip install gunicorn
pip install jupyter
pip install matplotlib
pip install seaborn- Start the Flask application:
python app.py- Open your web browser and navigate to:
http://localhost:5000
-
Load your dataset:
- Enter the path to your CSV dataset in the "Dataset Path" field
- Click "Load Data" to process the dataset
-
Get recommendations:
- Enter an item ID in the "Item ID" field
- Click "Get Recommendations" to see similar items
Your dataset should be a CSV file with the following columns:
id: Unique identifier for each itemtitle: Title or name of the item- Additional features that will be used for recommendations
POST /load_data: Load and process a new datasetPOST /recommend: Get recommendations for a specific item ID
If you encounter any installation issues:
- Make sure you have the latest version of pip:
python -m pip install --upgrade pip- Install setuptools first:
pip install --upgrade setuptools wheel- If you still have issues, try creating a new virtual environment with Python 3.11:
python3.11 -m venv venvFeel free to submit issues and enhancement requests!