Spaces:
Running
Running
Update utils.py
Browse files
utils.py
CHANGED
@@ -147,6 +147,61 @@ PART_LOGO = """
|
|
147 |
<h1 style="font-size: 28px; margin-bottom: 2px;">Part DP AI</h1>
|
148 |
"""
|
149 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
150 |
|
151 |
def load_jsonl(input_file):
|
152 |
data = []
|
|
|
147 |
<h1 style="font-size: 28px; margin-bottom: 2px;">Part DP AI</h1>
|
148 |
"""
|
149 |
|
150 |
+
tasks_and_metrics_table_markdown = """
|
151 |
+
<div style="text-align: center;">
|
152 |
+
<table style="margin: 0 auto; border-collapse: collapse; width: 30%; text-align: left; border: 1px solid #ddd; font-size: 14px;">
|
153 |
+
<thead>
|
154 |
+
<tr style="background-color: #f2f2f2;">
|
155 |
+
<th style="padding: 8px; border: 1px solid #ddd; width: 65%;">Task</th>
|
156 |
+
<th style="padding: 8px; border: 1px solid #ddd; width: 35%;">Metric</th>
|
157 |
+
</tr>
|
158 |
+
</thead>
|
159 |
+
<tbody>
|
160 |
+
<tr>
|
161 |
+
<td style="padding: 8px; border: 1px solid #ddd; word-wrap: break-word;">FarsTail-Pair-Classification</td>
|
162 |
+
<td style="padding: 8px; border: 1px solid #ddd;">Average precision</td>
|
163 |
+
</tr>
|
164 |
+
<tr>
|
165 |
+
<td style="padding: 8px; border: 1px solid #ddd; word-wrap: break-word;">MIRACL-Reranking</td>
|
166 |
+
<td style="padding: 8px; border: 1px solid #ddd;">NDCG@10</td>
|
167 |
+
</tr>
|
168 |
+
<tr>
|
169 |
+
<td style="padding: 8px; border: 1px solid #ddd; word-wrap: break-word;">Wikipedia-Multilingual-Reranking</td>
|
170 |
+
<td style="padding: 8px; border: 1px solid #ddd;">MAP</td>
|
171 |
+
</tr>
|
172 |
+
<tr>
|
173 |
+
<td style="padding: 8px; border: 1px solid #ddd; word-wrap: break-word;">NeuCLIR2023-Retrieval</td>
|
174 |
+
<td style="padding: 8px; border: 1px solid #ddd;">NDCG@20</td>
|
175 |
+
</tr>
|
176 |
+
<tr>
|
177 |
+
<td style="padding: 8px; border: 1px solid #ddd; word-wrap: break-word;">MIRACL-Retrieval</td>
|
178 |
+
<td style="padding: 8px; border: 1px solid #ddd;">NDCG@10</td>
|
179 |
+
</tr>
|
180 |
+
<tr>
|
181 |
+
<td style="padding: 8px; border: 1px solid #ddd; word-wrap: break-word;">Wikipedia-Multilingual-Retrieval</td>
|
182 |
+
<td style="padding: 8px; border: 1px solid #ddd;">NDCG@10</td>
|
183 |
+
</tr>
|
184 |
+
<tr>
|
185 |
+
<td style="padding: 8px; border: 1px solid #ddd; word-wrap: break-word;">Massive-Intent-Classification</td>
|
186 |
+
<td style="padding: 8px; border: 1px solid #ddd;">Accuracy</td>
|
187 |
+
</tr>
|
188 |
+
<tr>
|
189 |
+
<td style="padding: 8px; border: 1px solid #ddd; word-wrap: break-word;">Massive-Scenario-Classification</td>
|
190 |
+
<td style="padding: 8px; border: 1px solid #ddd;">Accuracy</td>
|
191 |
+
</tr>
|
192 |
+
<tr>
|
193 |
+
<td style="padding: 8px; border: 1px solid #ddd; word-wrap: break-word;">Multilingual-Sentiment-Classification</td>
|
194 |
+
<td style="padding: 8px; border: 1px solid #ddd;">Accuracy</td>
|
195 |
+
</tr>
|
196 |
+
<tr>
|
197 |
+
<td style="padding: 8px; border: 1px solid #ddd; word-wrap: break-word;">Persian-Food-Sentiment-Classification</td>
|
198 |
+
<td style="padding: 8px; border: 1px solid #ddd;">Accuracy</td>
|
199 |
+
</tr>
|
200 |
+
</tbody>
|
201 |
+
</table>
|
202 |
+
</div>
|
203 |
+
"""
|
204 |
+
|
205 |
|
206 |
def load_jsonl(input_file):
|
207 |
data = []
|