Spaces:
Sleeping
Sleeping
Update app.py
Browse files
app.py
CHANGED
@@ -22,6 +22,9 @@ if st.button("ตรวจสอบ"):
|
|
22 |
# แสดงผลลัพธ์
|
23 |
st.write("ผลลัพธ์:")
|
24 |
st.write(f"ข้อความ: {user_input}")
|
|
|
|
|
|
|
25 |
st.write(f"แสปม: {result[0]['label']}")
|
26 |
st.write(f"ความมั่นใจ: {result[0]['score']}")
|
27 |
else:
|
|
|
22 |
# แสดงผลลัพธ์
|
23 |
st.write("ผลลัพธ์:")
|
24 |
st.write(f"ข้อความ: {user_input}")
|
25 |
+
|
26 |
+
# แก้ไขข้อความ "Staff" เป็น "Spam"
|
27 |
+
label = "Spam" if result[0]['label'] == 'Staff' else result[0]['label']
|
28 |
st.write(f"แสปม: {result[0]['label']}")
|
29 |
st.write(f"ความมั่นใจ: {result[0]['score']}")
|
30 |
else:
|