Create Vector Search indexes
To start using Vector Search, you must configure another search index on your database. The process is similar to what you have done in the last section.
Step-by-step guide to creating your Vector Search index​
Open the Database Deployments page in MongoDB Atlas and select Create Index in the lower right corner.
Click the Create Search Index button.
This time, you will use the JSON Editor to create your index
Select your database and collection, change the index name to
vectorsearch
, and add the following code in the JSON editor:
{
"mappings": {
"dynamic": true,
"fields": {
"plot_embedding": {
"dimensions": 1536,
"similarity": "cosine",
"type": "knnVector"
}
}
}
}
Your configuration should look like this.

- The final step allows you to review the index configuration and refine it if needed. Go ahead and click Create Search Index.