diff --git a/lm_eval/tasks/opengptx/flores200.py b/lm_eval/tasks/opengptx/flores200.py index 68b5b19271..cc09e02779 100644 --- a/lm_eval/tasks/opengptx/flores200.py +++ b/lm_eval/tasks/opengptx/flores200.py @@ -60,9 +60,7 @@ def construct_requests(self, doc, ctx): language description, as well as the few shot examples, and the question part of the document for `doc`. """ - return [ - rf.loglikelihood_rolling(ctx) - ] + return [rf.loglikelihood_rolling(ctx)] def process_results(self, doc, results): ll = results[0] @@ -91,7 +89,7 @@ def higher_is_better(self): } def __str__(self): - return f"Flores200 Perplexity Task for {self.language}" + return f"Flores200 Perplexity Task for {self.language}" def create_ppl_task(lang, version=0): @@ -105,9 +103,7 @@ def __init__(self): def construct_lang_tasks(): - return { - f"flores200-lang-{lang}": create_ppl_task(lang) for lang in _LANGUAGES - } + return {f"flores200-lang-{lang}": create_ppl_task(lang) for lang in _LANGUAGES} class FloresTranslationTask(Task): @@ -224,7 +220,8 @@ def construct_trans_tasks(): for src, tgt in permutations(_LANGUAGES, 2) } -_LANGUAGES=[ + +_LANGUAGES = [ # "ace_Arab", # "ace_Latn", # "acm_Arab", @@ -429,4 +426,4 @@ def construct_trans_tasks(): # "zho_Hant", # "zsm_Latn", # "zul_Latn", -] \ No newline at end of file +]