Downloads · 30 days
0
cheesyFishes/llamaindex_ada002_bm25_fusion
llamaindex_ada002_bm25_fusion is a machine learning model from cheesyFishes. Use it for the machine learning task on the model card, and read the license before you ship it in a product. The card lists the license as mit.
This repo contains the code needed to run AIR-Bench using llamaindex.
Downloads · 30 days
0
Access
Public
Updated May 21, 2024
Repo size
—
Likes
0
Public
Click a slice to open those files.
.py3.9 KB · 64%
From the Hugging Face model README
This repo contains the code needed to run AIR-Bench using llamaindex.
In this repo, I implement a custom retriever that uses text-embedding-ada-002 as the dense embedding model, bm25 for sparse embeddings, and the QueryFusionRetriever() to combine results from these two, as well as generating extra queries for retrieval.
pip install llama-index llama-index-retrievers-bm25
python ./run_airbench.py
Feel free to use this as a template to evaluate other llama-index retrieval pipelines! You just need to customize the setup in create_retriever_fn() with the setup that you want to test against.