Spaces:
Build error
Build error
Preechanon Chatthai commited on
Update app.py
Browse files
app.py
CHANGED
|
@@ -106,8 +106,13 @@ def tokenize(text):
|
|
| 106 |
|
| 107 |
model = model_()
|
| 108 |
model.load_weights("cutto_tf2.h5")
|
| 109 |
-
|
|
|
|
| 110 |
text = st.text_area("Enter original text!")
|
| 111 |
-
|
| 112 |
-
|
| 113 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 106 |
|
| 107 |
model = model_()
|
| 108 |
model.load_weights("cutto_tf2.h5")
|
| 109 |
+
st.title("Cutto Thai word seggmentation.")
|
| 110 |
+
st.write("ปรีชานนท์ ชาติไทย และ สัจจวัจน์ ส่งเสริม. (2567), การสรุปข้อความข่าวภาษาไทยด้วยโครงข่ายประสาทเทียม (Thai News Text Summarization Using Neural Network), วิทยาศาสตรบัณฑิต (วทบ.):ขอนแก่น, มหาวิทยาลัยขอนแก่น")
|
| 111 |
text = st.text_area("Enter original text!")
|
| 112 |
+
if st.button("cut it!!"):
|
| 113 |
+
if text:
|
| 114 |
+
words = tokenize(text)
|
| 115 |
+
st.subheader("seggemt:")
|
| 116 |
+
st.write('|'.join(words))
|
| 117 |
+
else:
|
| 118 |
+
st.warning("Please enter some text to seggmentation")
|