Spaces:
Sleeping
Sleeping
Eric Hierholzer commited on
Commit ·
c15a4cb
1
Parent(s): 5de445a
updates
Browse files
README.md
CHANGED
|
@@ -11,7 +11,7 @@ short_description: "Netflix title recommendations using cosine similarity."
|
|
| 11 |
tags: ["recommendation", "netflix", "flask", "cosine-similarity", "docker"]
|
| 12 |
---
|
| 13 |
|
| 14 |
-
# Netflix
|
| 15 |
|
| 16 |
A Flask-based web application that provides personalized recommendations for Netflix content using a content-based filtering approach.
|
| 17 |
|
|
@@ -27,19 +27,24 @@ Ensure you have the following installed:
|
|
| 27 |
- **Node.js and npm** (Check with `node -v` and `npm -v`)
|
| 28 |
- **pip** (Python package manager)
|
| 29 |
|
| 30 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 31 |
|
| 32 |
### 1. Clone the Repository
|
| 33 |
```sh
|
| 34 |
-
git clone https://
|
| 35 |
-
cd
|
| 36 |
```
|
| 37 |
|
| 38 |
### 2. Set Up a Virtual Environment
|
| 39 |
|
| 40 |
#### macOS & Linux
|
| 41 |
```sh
|
| 42 |
-
python3 -m venv venv
|
| 43 |
source venv/bin/activate
|
| 44 |
```
|
| 45 |
|
|
@@ -63,27 +68,21 @@ npm install
|
|
| 63 |
```
|
| 64 |
|
| 65 |
### 4. Download Dataset
|
| 66 |
-
|
|
|
|
| 67 |
|
| 68 |
-
### 5. Build or Load Model
|
| 69 |
Run the following command to preprocess the dataset and generate a similarity model:
|
| 70 |
|
| 71 |
```sh
|
| 72 |
-
|
| 73 |
```
|
| 74 |
|
| 75 |
This will load the Netflix dataset, process it, and save a cached similarity model (`cosine_sim_cache.pkl`).
|
| 76 |
|
| 77 |
-
## Running the Application
|
| 78 |
-
|
| 79 |
-
Once setup is complete, start the Flask server:
|
| 80 |
-
|
| 81 |
-
```sh
|
| 82 |
-
python recommend_app.py
|
| 83 |
-
```
|
| 84 |
-
|
| 85 |
The app will be available at:
|
| 86 |
-
[http://
|
|
|
|
| 87 |
|
| 88 |
## Frontend Development
|
| 89 |
If making changes to the frontend, ensure Node.js dependencies are installed. Run:
|
|
@@ -129,12 +128,11 @@ docker build -t my-recommend-app .
|
|
| 129 |
docker run -p 7860:7860 my-recommend-app
|
| 130 |
```
|
| 131 |
|
| 132 |
-
access app at http://0.0.0.0:7860
|
| 133 |
|
| 134 |
-
#### Run with gunicorn
|
| 135 |
```sh
|
| 136 |
gunicorn -w 2 -b 0.0.0.0:7860 recommend_app:app
|
| 137 |
-
```
|
|
|
|
| 138 |
|
| 139 |
-
#### Just view online (easiest)
|
| 140 |
-
https://huggingface.co/spaces/erichier/finalcapstone
|
|
|
|
| 11 |
tags: ["recommendation", "netflix", "flask", "cosine-similarity", "docker"]
|
| 12 |
---
|
| 13 |
|
| 14 |
+
# Netflix Recommender App
|
| 15 |
|
| 16 |
A Flask-based web application that provides personalized recommendations for Netflix content using a content-based filtering approach.
|
| 17 |
|
|
|
|
| 27 |
- **Node.js and npm** (Check with `node -v` and `npm -v`)
|
| 28 |
- **pip** (Python package manager)
|
| 29 |
|
| 30 |
+
|
| 31 |
+
## View application online (easiest method)
|
| 32 |
+
https://huggingface.co/spaces/erichier/finalcapstone
|
| 33 |
+
|
| 34 |
+
|
| 35 |
+
## Manual Installation
|
| 36 |
|
| 37 |
### 1. Clone the Repository
|
| 38 |
```sh
|
| 39 |
+
git clone https://huggingface.co/spaces/erichier/finalcapstone
|
| 40 |
+
cd finalcapstone
|
| 41 |
```
|
| 42 |
|
| 43 |
### 2. Set Up a Virtual Environment
|
| 44 |
|
| 45 |
#### macOS & Linux
|
| 46 |
```sh
|
| 47 |
+
python3.12 -m venv venv
|
| 48 |
source venv/bin/activate
|
| 49 |
```
|
| 50 |
|
|
|
|
| 68 |
```
|
| 69 |
|
| 70 |
### 4. Download Dataset
|
| 71 |
+
Verify `netflix_titles.csv` is placed present from git clone.
|
| 72 |
+
Available here if needed: https://www.kaggle.com/datasets/shivamb/netflix-shows
|
| 73 |
|
| 74 |
+
### 5. Build or Load Model & Run Application
|
| 75 |
Run the following command to preprocess the dataset and generate a similarity model:
|
| 76 |
|
| 77 |
```sh
|
| 78 |
+
gunicorn -w 2 -b 0.0.0.0:7860 recommend_app:app
|
| 79 |
```
|
| 80 |
|
| 81 |
This will load the Netflix dataset, process it, and save a cached similarity model (`cosine_sim_cache.pkl`).
|
| 82 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 83 |
The app will be available at:
|
| 84 |
+
Access app at [http://0.0.0.0:7860] or [http://localhost:7860]
|
| 85 |
+
|
| 86 |
|
| 87 |
## Frontend Development
|
| 88 |
If making changes to the frontend, ensure Node.js dependencies are installed. Run:
|
|
|
|
| 128 |
docker run -p 7860:7860 my-recommend-app
|
| 129 |
```
|
| 130 |
|
| 131 |
+
access app at http://0.0.0.0:7860 or http://localhost:7860
|
| 132 |
|
| 133 |
+
<!-- #### Run with gunicorn
|
| 134 |
```sh
|
| 135 |
gunicorn -w 2 -b 0.0.0.0:7860 recommend_app:app
|
| 136 |
+
``` -->
|
| 137 |
+
|
| 138 |
|
|
|
|
|
|