Skip to main content

llama-index retrievers mongodb-atlas-bm25-retriever integration

Project description

LlamaIndex Retrievers Integration: MongoDBAtlasBM25Retriever

What is this?

This is a BM25 Retriever for MongoDB Atlas that can be used with LlamaIndex.

How to use

This was created with reference to MongoDBAtlasVectorSearch, so it's mostly the same.

Please refer to that.

However, while MongoDBAtlasVectorSearch is an VectorStore, MongoDBAtlasBM25Retriever is a Retriever.

MongoDBAtlasBM25Retriever Example:

mongodb_client = pymongo.MongoClient(mongo_uri)

retriever = MongoDBAtlasBM25Retriever(
    mongodb_client=mongodb_client,
    db_name="vectorstore",
    collection_name="vector_collection",
    index_name="index_vector_collection",
)
nodes = retriever.retrieve("retrieve_query")

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

Built Distribution

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page