ogawaal commited on
Commit
67015b4
·
verified ·
1 Parent(s): d29ce9c

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +1 -0
app.py CHANGED
@@ -36,6 +36,7 @@ if st.button("判定", key="run"):
36
  st.markdown(f"判定結果: **{ID2CAT[pred_class]}**")
37
  if pred_class == 1:
38
  topic_dist, ll = infer_topic(user_input)
 
39
  words_atten = get_word_attn(input_ids, attention_list)
40
  html_hext_result = html_hext(((word, attn) for word, attn in words_atten))
41
  st.markdown(html_hext_result, unsafe_allow_html=True)
 
36
  st.markdown(f"判定結果: **{ID2CAT[pred_class]}**")
37
  if pred_class == 1:
38
  topic_dist, ll = infer_topic(user_input)
39
+ st.markdown(topic_dist)
40
  words_atten = get_word_attn(input_ids, attention_list)
41
  html_hext_result = html_hext(((word, attn) for word, attn in words_atten))
42
  st.markdown(html_hext_result, unsafe_allow_html=True)