herztard commited on
Commit
c1f2ce7
·
1 Parent(s): b7edde4
Files changed (1) hide show
  1. app.py +3 -1
app.py CHANGED
@@ -39,7 +39,9 @@ if st.button("Get tags"):
39
  st.write("**Extracted Article Text:**")
40
  st.write(article_text[:500] + "...")
41
 
42
- result = model(article_text, categories, multi_label=True)
 
 
43
  st.write("**Predicted Tags:**")
44
  for label, score in zip(result["labels"], result["scores"]):
45
  st.write(f"- {label}: {score:.2f}")
 
39
  st.write("**Extracted Article Text:**")
40
  st.write(article_text[:500] + "...")
41
 
42
+ with st.spinner("Analyzing... Please wait."):
43
+ result = model(article_text[:512], categories, multi_label=True)
44
+
45
  st.write("**Predicted Tags:**")
46
  for label, score in zip(result["labels"], result["scores"]):
47
  st.write(f"- {label}: {score:.2f}")