abdulmatinomotoso commited on
Commit
f622ee3
1 Parent(s): b38722e

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +2 -2
app.py CHANGED
@@ -30,8 +30,8 @@ def final_summary(file):
30
  output = []
31
 
32
  #looping through the sentences in a batch of 10 and summarizing them
33
- for i in range(0,len(chunks), 20):
34
- sentence = ' '.join(chunks[i:i+20])
35
  inputs = tokenizer(sentence, max_length=1024, return_tensors="pt")
36
  summary_ids = model.generate(inputs["input_ids"])
37
  summary = tokenizer.batch_decode(summary_ids, skip_special_tokens=True, clean_up_tokenization_spaces=False)[0]
 
30
  output = []
31
 
32
  #looping through the sentences in a batch of 10 and summarizing them
33
+ for i in range(0,len(chunks), 10):
34
+ sentence = ' '.join(chunks[i:i+10])
35
  inputs = tokenizer(sentence, max_length=1024, return_tensors="pt")
36
  summary_ids = model.generate(inputs["input_ids"])
37
  summary = tokenizer.batch_decode(summary_ids, skip_special_tokens=True, clean_up_tokenization_spaces=False)[0]