I’m doing some testing with the Mongo Atlas free tier. The free tier appears to only support version 6. The pymongo docs suggest that Atlas 7.0+ is required to call collection.create_search_index
. However, since I am able to create the search index on the web console using the JSON editor, I just wanted to confirm if this is still the case.
I’ve tried the following:
search_index_model = operations.SearchIndexModel(
definition={
"mappings": {
"dynamic": True,
"fields": {
"values": {
"type": "knnVector",
"dimensions": 768,
"similarity": "cosine",
}
},
},
},
name="embeddings2",
)
collection.create_search_index(model=search_index_model)
But it fails with OperationFailure: command not found
.