gabrielwithhappy commited on
Commit
d162cd8
1 Parent(s): e187645

update length_penalty

Browse files
Files changed (1) hide show
  1. app.py +1 -1
app.py CHANGED
@@ -17,7 +17,7 @@ def get_summary(input_text):
17
  summary_model = BartForConditionalGeneration.from_pretrained("ainize/kobart-news")
18
  input_ids = tokenizer.encode(input_text, return_tensors="pt")
19
  summary_text_ids = summary_model.generate(
20
- length_penalty=0,
21
  top_p=0.9,
22
  max_length=128,
23
  min_length=12,
 
17
  summary_model = BartForConditionalGeneration.from_pretrained("ainize/kobart-news")
18
  input_ids = tokenizer.encode(input_text, return_tensors="pt")
19
  summary_text_ids = summary_model.generate(
20
+ length_penalty=1,
21
  top_p=0.9,
22
  max_length=128,
23
  min_length=12,