MCPcopy Create free account
hub / github.com/OpenBitSys/BitDistiller / construct_requests

Method construct_requests

test/general/lm_eval/tasks/mutual.py:64–68  ·  view source on GitHub ↗
(self, doc, ctx)

Source from the content-addressed store, hash-verified

62 return " " + self.detokenize(doc["options"][self.CHOICES.index(doc["answers"])])
63
64 def construct_requests(self, doc, ctx):
65 lls = []
66 for option in doc["options"]:
67 lls.append(rf.loglikelihood(ctx, f" {self.detokenize(option)}")[0])
68 return lls
69
70 def detokenize(self, text):
71 text = text.replace(" '", "'")

Callers

nothing calls this directly

Calls 2

detokenizeMethod · 0.95
loglikelihoodMethod · 0.45

Tested by

no test coverage detected