- Docker
- Elastic Search
- FastAPI
- SBERT
- NLTK
-
Make a virtual environment with python 3.10.2
python3.10.2 -m venv {env_name}
-
Run virtual env and install dependencies
./{env_name}/Scripts/activate // for windows source {env_name}/bin/activate // for linux pip install -r requirements.txt
-
Create a .secrets.toml file to store environment variables. Add following variables
elastic_username = "{username}" elastic_password = "{password}"
-
Create docker containers for elastic search and kibana.
docker-compose up
-
Index data in elastic search.
python ElasticIndexer.py
-
Run FastAPI server
uvicorn app:app
-
Go to http://localhost:8000/docs to test the API.
Content Based Filtering is a type of recommendation generation system that used metadata of an item to find other similar items. The metadata for a movie would be its title, plot, cast, directors, genre, and so on. The metadata is then used to create a single document by combing them. The document in then encoded to a vector which represents that movie in the latent space. To generate recommendations for user that has liked a particular movie, the similarity is computed between that movie vector with all other movie vector. Most similar movie vectors can then be recommended to the users.
- Input: The Lion King
- Input: Space Aliens