Update README.md
Browse files
README.md
CHANGED
|
@@ -2,6 +2,7 @@ This is the IndicBART model. For detailed documentation look here: https://indic
|
|
| 2 |
|
| 3 |
Usage:
|
| 4 |
|
|
|
|
| 5 |
from transformers import MBartForConditionalGeneration
|
| 6 |
from transformers import AlbertTokenizer
|
| 7 |
|
|
@@ -42,7 +43,7 @@ model_output=model.generate(inp, use_cache=True, num_beams=4, max_length=20, min
|
|
| 42 |
decoded_output=tokenizer.decode(model_output[0], skip_special_tokens=True, clean_up_tokenization_spaces=False)
|
| 43 |
|
| 44 |
print(decoded_output) # I am happy
|
| 45 |
-
|
| 46 |
|
| 47 |
Notes:
|
| 48 |
1. This is compatible with the latest version of transformers but was developed with version 4.3.2 so consider using 4.3.2 if possible.
|
|
|
|
| 2 |
|
| 3 |
Usage:
|
| 4 |
|
| 5 |
+
```
|
| 6 |
from transformers import MBartForConditionalGeneration
|
| 7 |
from transformers import AlbertTokenizer
|
| 8 |
|
|
|
|
| 43 |
decoded_output=tokenizer.decode(model_output[0], skip_special_tokens=True, clean_up_tokenization_spaces=False)
|
| 44 |
|
| 45 |
print(decoded_output) # I am happy
|
| 46 |
+
```
|
| 47 |
|
| 48 |
Notes:
|
| 49 |
1. This is compatible with the latest version of transformers but was developed with version 4.3.2 so consider using 4.3.2 if possible.
|