"vscode:/vscode.git/clone" did not exist on "55f5fc68acc84027a275649d2cfb320448ed95d7"
Commit 03b9db6b authored by haileyschoelkopf's avatar haileyschoelkopf
Browse files

revert mutual info whitespace change

parent b250b001
...@@ -718,12 +718,14 @@ class ConfigurableTask(Task): ...@@ -718,12 +718,14 @@ class ConfigurableTask(Task):
raise TypeError raise TypeError
def gold_alias(self, doc): def gold_alias(self, doc):
# TODO: reevaluate if we need this. implemented to have a # returns a version of the gold target answer to a document,
# processed version of answer to put into gsm8k exact_match scoring as ref. # which should be passed into metric for scoring as the ground truth.
# in multiple_choice tasks, this should be castable to an int corresponding to the index
# within the answer choices, while doc_to_target is the string version of {{answer_choices[gold]}}.
if self._config.gold_alias is not None: if self._config.gold_alias is not None:
doc_to_target = self._config.gold_alias doc_to_target = self._config.gold_alias
else: else:
# doc_to_target = self._config.doc_to_target
return self.doc_to_target(doc) return self.doc_to_target(doc)
if type(doc_to_target) == str: if type(doc_to_target) == str:
...@@ -772,7 +774,7 @@ class ConfigurableTask(Task): ...@@ -772,7 +774,7 @@ class ConfigurableTask(Task):
Instance( Instance(
request_type="loglikelihood", request_type="loglikelihood",
doc=doc, doc=doc,
arguments=("", " {}".format(choice)), arguments=("", "{}".format(choice)),
idx=i, idx=i,
**kwargs, **kwargs,
) )
......
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