From 0528f297ae84255aa7019232bfa1c7af870a54f2 Mon Sep 17 00:00:00 2001 From: Sadra Barikbin Date: Mon, 8 Jul 2024 12:34:11 +0330 Subject: [PATCH] Fix the bug (#216) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Co-authored-by: Clémentine Fourrier <22726840+clefourrier@users.noreply.github.com> --- src/lighteval/tasks/lighteval_task.py | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/src/lighteval/tasks/lighteval_task.py b/src/lighteval/tasks/lighteval_task.py index 33934caa0..fa70b61da 100644 --- a/src/lighteval/tasks/lighteval_task.py +++ b/src/lighteval/tasks/lighteval_task.py @@ -538,6 +538,18 @@ def construct_requests( generation_size=self.generation_size, ) ] + if self.has_metric_category[MetricCategory.LLM_AS_JUDGE]: + requests[RequestType.GREEDY_UNTIL] += [ + GreedyUntilRequest( + task_name=current_task_name, + example_index=document_id_seed, + request_index=0, + context=context, + stop_sequence=self.stop_sequence, + generation_size=self.generation_size, + num_samples=1, + ) + ] return requests