From ca125da0eb81d93622b9cb9ac9183956e3e51582 Mon Sep 17 00:00:00 2001 From: YC Chen Date: Wed, 2 Aug 2023 14:35:35 +0800 Subject: [PATCH] [fix] Remove useless code --- src/llmtuner/extras/template.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/llmtuner/extras/template.py b/src/llmtuner/extras/template.py index e85e0f35..567b9102 100644 --- a/src/llmtuner/extras/template.py +++ b/src/llmtuner/extras/template.py @@ -65,7 +65,7 @@ class Llama2Template(Template): if turn_idx == 0: convs.append([self.prompt.format(query=sys+query_i), resp_i]) else: - convs.append([(self.sep if turn_idx else prefix) + self.prompt.format(query=query_i), resp_i]) + convs.append([self.sep + self.prompt.format(query=query_i), resp_i]) return convs