1998Shubh/codingchallenge
0
1# Content-Based Book Recommender System2 3This project implements a content-based book recommender system using Python. It leverages book summaries and categories to calculate similarities between books and recommends the top 5 similar books based on the input book title. The system is deployed using a simple Streamlit web application.4 5## Features6- Recommends books based on their content (summaries and categories).7- Uses TF-IDF vectorization for feature extraction and cosine similarity for comparison.8- Provides a web interface for input and displaying recommendations.9 10## Dataset ((https://www.kaggle.com/datasets/arpansri/books-summary))11The dataset used contains the following columns:12- `book_name`: The title of the book.13- `summaries`: A summary of the book.14- `categories`: Categories or genres associated with the book.15 16 17 18## Dependencies19The following Python libraries are required to run the project:20 21| Library | Version | Functionality |22|---------------|---------|-------------------------------------------------------------------------------|23| `pandas` | 1.3.5 | For reading, processing, and handling the dataset (`books_summary.csv`). |24| `streamlit` | 1.25.0 | For building and running the interactive web application. |25| `scikit-learn`| 1.2.2 | For TF-IDF vectorization and cosine similarity calculations. |26| `nltk` | 3.8.1 | For natural language processing (stopword removal and text cleaning). |27 28### Explanation of Dependencies by File291. **`app.py`**:30 - **`streamlit`**: Used to build the user interface and provide interactivity (e.g., text input for book title, button for recommendations, and displaying results).31 - **`pandas`**: Loads and preprocesses the dataset.32 - **`nltk`**: Cleans and preprocesses textual data (`summaries` and `categories`) by removing stopwords and punctuation.33 342. **`recommender.py`**:35 - **`pandas`**: Handles and manipulates the book dataset.36 - **`scikit-learn`**: 37 - Uses `TfidfVectorizer` for extracting features from the `summaries` and `categories` columns.38 - Uses `cosine_similarity` for calculating the similarity between books.