Spaces:
Running
Running
Skip special tokens
Browse files
app.py
CHANGED
|
@@ -55,7 +55,7 @@ def translate(text, source_lang="English", target_lang="Tachelhit/Central Atlas
|
|
| 55 |
)
|
| 56 |
target = results[0].hypotheses[0][1:]
|
| 57 |
|
| 58 |
-
translation = nllb_tokenizer.decode(nllb_tokenizer.convert_tokens_to_ids(target))
|
| 59 |
|
| 60 |
translations.append(translation)
|
| 61 |
|
|
|
|
| 55 |
)
|
| 56 |
target = results[0].hypotheses[0][1:]
|
| 57 |
|
| 58 |
+
translation = nllb_tokenizer.decode(nllb_tokenizer.convert_tokens_to_ids(target), skip_special_tokens=True)
|
| 59 |
|
| 60 |
translations.append(translation)
|
| 61 |
|