Spaces:
Sleeping

SoniaD commited on
Commit
30758f4
·
verified ·
1 Parent(s): 1068dc3

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +1 -1
app.py CHANGED
@@ -51,7 +51,7 @@ def analyze_reviews(uploaded_file):
51
  try:
52
  token_len = len(tokenizer(complaint)["input_ids"])
53
  if token_len > 40:
54
- summary = summarizer(complaint, max_length=20, do_sample=False)[0]["summary_text"]
55
  else:
56
  summary = complaint
57
  topic_result = zero_classifier(summary, candidate_labels)
 
51
  try:
52
  token_len = len(tokenizer(complaint)["input_ids"])
53
  if token_len > 40:
54
+ summary = summarizer(complaint, max_length=50, min_length=15, do_sample=False)[0]["summary_text"]
55
  else:
56
  summary = complaint
57
  topic_result = zero_classifier(summary, candidate_labels)