Spaces:
Runtime error
Runtime error
Update app.py
Browse files
app.py
CHANGED
@@ -30,7 +30,8 @@ def run_model(input_text,
|
|
30 |
min_length = min_length, #Panjang minimum urutan yang akan dihasilkan)
|
31 |
max_length = max_length, #Panjang maksimum urutan yang akan dihasilkan)"""
|
32 |
num_beams = 3,
|
33 |
-
|
|
|
34 |
|
35 |
#decode output to text
|
36 |
output = mbart_tokenizer.batch_decode(summary_ids, skip_special_tokens=True, clean_up_tokenization_spaces=False)
|
|
|
30 |
min_length = min_length, #Panjang minimum urutan yang akan dihasilkan)
|
31 |
max_length = max_length, #Panjang maksimum urutan yang akan dihasilkan)"""
|
32 |
num_beams = 3,
|
33 |
+
no_repeat_ngram_size = 2,
|
34 |
+
early_stopping = True)
|
35 |
|
36 |
#decode output to text
|
37 |
output = mbart_tokenizer.batch_decode(summary_ids, skip_special_tokens=True, clean_up_tokenization_spaces=False)
|