CO-IR commited on
Commit
1ca5257
1 Parent(s): f6bae00

Update README.md

Browse files
Files changed (1) hide show
  1. README.md +23 -2
README.md CHANGED
@@ -27,6 +27,27 @@ dataset_info:
27
  download_size: 0
28
  dataset_size: 19678114
29
  ---
30
- # Dataset Card for "apps-queries-corpus"
 
 
 
 
 
31
 
32
- [More Information needed](https://github.com/huggingface/datasets/blob/main/CONTRIBUTING.md#how-to-contribute-to-the-dataset-cards)
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
27
  download_size: 0
28
  dataset_size: 19678114
29
  ---
30
+ Employing the CoIR evaluation framework's dataset version, utilize the code below for assessment:
31
+ ```python
32
+ import coir
33
+ from coir.data_loader import get_tasks
34
+ from coir.evaluation import COIR
35
+ from coir.models import YourCustomDEModel
36
 
37
+ model_name = "intfloat/e5-base-v2"
38
+
39
+ # Load the model
40
+ model = YourCustomDEModel(model_name=model_name)
41
+
42
+ # Get tasks
43
+ #all task ["codetrans-dl","stackoverflow-qa","apps","codefeedback-mt","codefeedback-st","codetrans-contest","synthetic-
44
+ # text2sql","cosqa","codesearchnet","codesearchnet-ccr"]
45
+ tasks = get_tasks(tasks=["codetrans-dl"])
46
+
47
+ # Initialize evaluation
48
+ evaluation = COIR(tasks=tasks,batch_size=128)
49
+
50
+ # Run evaluation
51
+ results = evaluation.run(model, output_folder=f"results/{model_name}")
52
+ print(results)
53
+ ```