ogawaal commited on
Commit
49ebd54
·
verified ·
1 Parent(s): b4aceb8

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +1 -1
app.py CHANGED
@@ -34,9 +34,9 @@ if st.button("判定", key="run"):
34
  else:
35
  pred_class, input_ids, attention_list = classify_ma(user_input)
36
  st.markdown(f"判定結果: **{ID2CAT[pred_class]}**")
 
37
  if pred_class == 1:
38
  topic_dist,new_word_list, ll = infer_topic(user_input)
39
- st.markdown(new_word_list) #この一文を追加
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)
 
34
  else:
35
  pred_class, input_ids, attention_list = classify_ma(user_input)
36
  st.markdown(f"判定結果: **{ID2CAT[pred_class]}**")
37
+ st.markdown(new_word_list) #この一文を追加
38
  if pred_class == 1:
39
  topic_dist,new_word_list, ll = infer_topic(user_input)
 
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)