"llm/vscode:/vscode.git/clone" did not exist on "9d91e5e5875e2b2f8605ef15a7da9a616cb05171"
Commit c117e787 authored by Oleh Shliazhko's avatar Oleh Shliazhko
Browse files

fix unreachable return

parent f034974a
......@@ -159,7 +159,6 @@ class GeneralHendrycksTest(MultipleChoiceTask):
"choices": keys,
"gold": doc["answer"],
}
return result
def fewshot_examples(self, k, rnd):
# fewshot_examples is not just sampling from train_docs because dev is
......@@ -167,9 +166,9 @@ class GeneralHendrycksTest(MultipleChoiceTask):
if self._fewshot_docs is None:
self._fewshot_docs = list(map(self._process_doc, self.dataset["dev"]))
# use the unchanged order of the dev set without sampling,
# use the unchanged order of the dev set without sampling,
# just as in the original code https://github.com/hendrycks/test/blob/master/evaluate.py#L28
return self._fewshot_docs[:k]
return self._fewshot_docs[:k]
def doc_to_text(self, doc):
return doc["query"]
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment