Skip to content

Commit

Permalink
fix bug about template 3 (PaddlePaddle#3646)
Browse files Browse the repository at this point in the history
  • Loading branch information
westfish authored Nov 2, 2022
1 parent e94af79 commit 228c58a
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion paddlenlp/taskflow/question_generation.py
Original file line number Diff line number Diff line change
Expand Up @@ -191,7 +191,7 @@ def _convert_example(self,
target = '在已知答案的前提下,问题:' + target
elif self._template == 3:
### use template 3
source = '这是一个问题生成任务,根据提供的答案和上下文,来生成问题。' + title + tokenizer.sep_token + '上下文:' + source
source = '这是一个问题生成任务,根据提供的答案和上下文,来生成问题。' + title + self._tokenizer.sep_token + '上下文:' + source
title = None
if target:
target = '问题:' + target
Expand Down

0 comments on commit 228c58a

Please sign in to comment.