Quick start project on Mongo DB with Python loading all Lego sets data from CSV file.
- Create an Atlas account and cluster.
- Create a database named
learning
and a collection namedlegoflix
. - Create a user with read/write access to the database.
- Create a
.env
from the template file.
To set up embeddings in Atlas, follow the instructions in this tutorial to create a Vector Search. Add the following index.
{
"mappings": {
"dynamic": true,
"fields": {
"plot_embedding": {
"dimensions": 1536,
"similarity": "cosine",
"type": "knnVector"
}
}
}
}
- Run
python loader.py
to load the data into the database. - Run
python main.py
to search for a lego set.