This commit is contained in:
Nick Walton
2019-09-26 12:14:45 -06:00
parent aa07103aee
commit 34b0e687e0
2 changed files with 3 additions and 1 deletions
+1 -1
View File
@@ -216,7 +216,7 @@ class CTRLGenerator():
prompt_logits[_token][generated_token] /= self.penalty
# disallow some tokens
forbidden_tokens = ['<unk>', 'Sco@@']
forbidden_tokens = ['<unk>', 'Sco@@', "&amp@@", "1]@@", "2]@@", "3]@@", "4]@@", "https://www.@@", "[@@"]
if num_new_lines > self.max_new_lines:
forbidden_tokens.append("\n")