Skip to content

Commit

Permalink
Update docs/source/ar/multilingual.md
Browse files Browse the repository at this point in the history
Co-authored-by: Abdullah Mohammed <554032+abodacs@users.noreply.github.com>
  • Loading branch information
AhmedAlmaghz and abodacs authored Oct 26, 2024
1 parent 4767d64 commit a420425
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion docs/source/ar/multilingual.md
Original file line number Diff line number Diff line change
Expand Up @@ -113,7 +113,7 @@
>>> encoded_zh = tokenizer(chinese_text, return_tensors="pt")
```

يجبر M2M100 معرف اللغة الهدف كأول رمز مولد للترجمة إلى لغة الهدف. قم بتعيين `forced_bos_token_id` إلى `en` في طريقة `generate` للترجمة إلى الإنجليزية:
يجبر M2M100 معرف اللغة الهدف كأول رمز مولد للترجمة إلى اللغة الهدف. قم بتعيين `forced_bos_token_id` إلى `en` في طريقة `generate` للترجمة إلى الإنجليزية:

```py
>>> generated_tokens = model.generate(**encoded_zh, forced_bos_token_id=tokenizer.get_lang_id("en"))
Expand Down

0 comments on commit a420425

Please sign in to comment.