AnkurKumar77/book_recommender_kaggle_dataset
0
Check out the configuration reference at https://huggingface.co/docs/hub/spaces-config-reference
Book Recommendation System
Overview
This project provides a book recommendation system based on book summaries. It uses TF-IDF vectorization and cosine similarity to find similar books.
Dependencies
pandas(Used inload_data,preprocess_data)sklearn.feature_extraction.text.TfidfVectorizer(Used incompute_tfidf)sklearn.metrics.pairwise.cosine_similarity(Used incompute_tfidf)numpy(Used inrecommend_books)gradio(Used in the interface setup)
Functionality Breakdown
1. load_data(csv_path)
- Dependencies:
pandas - Description: Loads the dataset from a CSV file and removes missing values.
2. preprocess_data(df)
- Dependencies:
pandas - Description: Groups multiple summaries for the same book and combines them into a single entry.
3. compute_tfidf(df)
- Dependencies:
sklearn.feature_extraction.text.TfidfVectorizer,sklearn.metrics.pairwise.cosine_similarity - Description: Converts book summaries into TF-IDF feature vectors and computes cosine similarity between them.
4. recommend_books(book_name, df, cosine_sim)
- Dependencies:
numpy,pandas - Description: Finds the most similar books based on the cosine similarity scores.
5. Gradio Interface
- Dependencies:
gradio - Description: Provides a simple user interface to input a book name and get recommendations.
