Spaces:
Paused
Paused
Fixed envs
Browse files
src/custom_tasks/heq_task.py
CHANGED
@@ -9,7 +9,7 @@ from lighteval.tasks.requests import Doc
|
|
9 |
from Levenshtein import distance
|
10 |
import collections
|
11 |
from lighteval.utils import as_list
|
12 |
-
from envs import OWNER
|
13 |
|
14 |
def get_tokens(s):
|
15 |
if not s:
|
|
|
9 |
from Levenshtein import distance
|
10 |
import collections
|
11 |
from lighteval.utils import as_list
|
12 |
+
from ..envs import OWNER
|
13 |
|
14 |
def get_tokens(s):
|
15 |
if not s:
|
src/custom_tasks/sentiment_task.py
CHANGED
@@ -9,7 +9,7 @@ from lighteval.tasks.requests import Doc
|
|
9 |
from Levenshtein import distance
|
10 |
import collections
|
11 |
from lighteval.utils import as_list
|
12 |
-
from envs import OWNER
|
13 |
|
14 |
def sentiment_eval_fn(golds: list[str], predictions: list[str], formatted_doc: Doc = None):
|
15 |
if len(predictions) > 1:
|
|
|
9 |
from Levenshtein import distance
|
10 |
import collections
|
11 |
from lighteval.utils import as_list
|
12 |
+
from ..envs import OWNER
|
13 |
|
14 |
def sentiment_eval_fn(golds: list[str], predictions: list[str], formatted_doc: Doc = None):
|
15 |
if len(predictions) > 1:
|
src/custom_tasks/translation_task.py
CHANGED
@@ -10,7 +10,7 @@ from Levenshtein import distance
|
|
10 |
import collections
|
11 |
from lighteval.utils import as_list
|
12 |
import sacrebleu
|
13 |
-
from envs import OWNER
|
14 |
|
15 |
def trans_prompt_fn(line, task_name: str = None):
|
16 |
"""Defines how to go from a dataset line to a doc object.
|
|
|
10 |
import collections
|
11 |
from lighteval.utils import as_list
|
12 |
import sacrebleu
|
13 |
+
from ..envs import OWNER
|
14 |
|
15 |
def trans_prompt_fn(line, task_name: str = None):
|
16 |
"""Defines how to go from a dataset line to a doc object.
|
src/custom_tasks/winograd_task.py
CHANGED
@@ -9,7 +9,7 @@ from lighteval.tasks.requests import Doc
|
|
9 |
from Levenshtein import distance
|
10 |
import collections
|
11 |
from lighteval.utils import as_list
|
12 |
-
from envs import OWNER
|
13 |
|
14 |
def winograd_eval_fn(golds: list[str], predictions: list[str], formatted_doc: Doc = None):
|
15 |
if len(predictions) > 1:
|
|
|
9 |
from Levenshtein import distance
|
10 |
import collections
|
11 |
from lighteval.utils import as_list
|
12 |
+
from ..envs import OWNER
|
13 |
|
14 |
def winograd_eval_fn(golds: list[str], predictions: list[str], formatted_doc: Doc = None):
|
15 |
if len(predictions) > 1:
|