From df227ac20d87cc99f39b690cabe074691b901420 Mon Sep 17 00:00:00 2001 From: OlivierDehaene Date: Thu, 2 Feb 2023 10:34:35 +0100 Subject: [PATCH] fix(server): allow greedy repetition penalty (#51) --- server/text_generation/utils.py | 1 - 1 file changed, 1 deletion(-) diff --git a/server/text_generation/utils.py b/server/text_generation/utils.py index 8590f85..8bbc737 100644 --- a/server/text_generation/utils.py +++ b/server/text_generation/utils.py @@ -73,7 +73,6 @@ class NextTokenChooser: sampling = True if repetition_penalty is not None and repetition_penalty != 1.0: warpers.append(RepetitionPenaltyLogitsProcessor(penalty=repetition_penalty)) - sampling = True self.warpers = warpers self.choice = Sampling(seed, device) if sampling else Greedy()