You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Hi, recently, I found your MMTEB work. The benchmark looks good. I would like to evaluate some models on this benchmark. Can you share a sample script for the evaluation? Thanks!
<summary> Running SentenceTransformer model with prompts </summary>
Prompts can be passed to the SentenceTransformer model using the `prompts` parameter. The following code shows how to use prompts with SentenceTransformer:
```python
from sentence_transformers import SentenceTransformer
model = SentenceTransformer("average_word_embeddings_komninos", prompts={"query": "Query:", "passage": "Passage:"})
evaluation = mteb.MTEB(tasks=tasks)
```
In prompts the key can be:
1. Prompt types (`passage`, `query`) - they will be used in reranking and retrieval tasks
2. Task type - these prompts will be used in all tasks of the given type
1.`BitextMining`
2.`Classification`
3.`MultilabelClassification`
4.`Clustering`
5.`PairClassification`
6.`Reranking`
7.`Retrieval`
8.`STS`
9.`Summarization`
10.`InstructionRetrieval`
3. Pair of task type and prompt type like `Retrival-query` - these prompts will be used in all classification tasks
4. Task name - these prompts will be used in the specific task
5. Pair of task name and prompt type like `NFCorpus-query` - these prompts will be used in the specific task
</details>
* Using CLI
```bash
mteb available_tasks
mteb run -m sentence-transformers/all-MiniLM-L6-v2 \
-t Banking77Classification \
--verbosity 3
# if nothing is specified default to saving the results in the results/{model_name} folder
Thanks for the quick response. Actually, I am looking for the evaluation script for the whole MMTEB (the benchmark, not one task from MTEB). It looks the pointed file only includes the evaluation of a task in MTEB.
Activity
Samoed commentedon Feb 24, 2025
You can find example scripts in readme
mteb/README.md
Lines 41 to 97 in 4d23c6c
lifu-tu commentedon Feb 24, 2025
Thanks for the quick response. Actually, I am looking for the evaluation script for the whole MMTEB (the benchmark, not one task from MTEB). It looks the pointed file only includes the evaluation of a task in MTEB.
Samoed commentedon Feb 24, 2025
Similarly you can run