Views
No views yet
model_type=bidir_mistral in config.json is no longer supported.Transformers 4.47.0.1import mteb
2from sentence_transformers import SparseEncoder
3
4model = SparseEncoder("Y-Research-Group/CSR-NV_Embed_v2-Retrieval-NFcorpus", trust_remote_code=True)
5model.prompts = {
6 "NFCorpus-query": "Instruct: Given a question, retrieve relevant documents that answer the question\nQuery:"
7}
8
9task = mteb.get_tasks(tasks=["NFCorpus"])
10evaluation = mteb.MTEB(tasks=task)
11evaluation.run(
12 model,
13 eval_splits=["test"],
14 output_folder="./results/NFCorpus",
15 show_progress_bar=True,
16 encode_kwargs={"convert_to_sparse_tensor": False, "batch_size": 8},
17) # MTEB don't support sparse tensors yet, so we need to convert to dense tensors1@misc{wen2025matryoshkarevisitingsparsecoding,
2 title={Beyond Matryoshka: Revisiting Sparse Coding for Adaptive Representation},
3 author={Tiansheng Wen and Yifei Wang and Zequn Zeng and Zhong Peng and Yudi Su and Xinyang Liu and Bo Chen and Hongwei Liu and Stefanie Jegelka and Chenyu You},
4 year={2025},
5 eprint={2503.01776},
6 archivePrefix={arXiv},
7 primaryClass={cs.LG},
8 url={https://arxiv.org/abs/2503.01776},
9}