Crystalcareai
commited on
Update generate.py
Browse files- generate.py +2 -5
generate.py
CHANGED
@@ -228,9 +228,6 @@ def generate(
|
|
228 |
**model_kwargs,
|
229 |
)
|
230 |
|
231 |
-
generated_text = self.tokenizer.decode(generated_token_ids[0], skip_special_tokens=True)
|
232 |
|
233 |
-
|
234 |
-
|
235 |
-
else:
|
236 |
-
return generated_token_ids, generated_text
|
|
|
228 |
**model_kwargs,
|
229 |
)
|
230 |
|
|
|
231 |
|
232 |
+
generated_text = self.tokenizer.decode(generated_token_ids[0], skip_special_tokens=False)
|
233 |
+
return generated_token_ids, generated_text
|
|
|
|