veer66 / wordcut

Thai word breaker for Node.js
GNU Lesser General Public License v3.0
141 stars 40 forks source link

ไม้ ๆ #16

Open kamontat opened 7 years ago

kamontat commented 7 years ago

พอโปรแกรมเจอ ไม้ มันก็เพี้ยนเลย

เธอ เฝ้า แต่ คอย ที่ จะ อ่าน หนังสือ ไป เรื่อ ยๆ เธอ ก็ รู ้สึ กเบื่ อๆ สายตา แปล กๆ

veer66 commented 7 years ago

Will this รู้สึก|เบื่อ|ๆ be acceptable?

tonyayna commented 7 years ago

น่าจะดีกว่านะครับ รู้สึก|เบื่อ|ๆ

kittipongint commented 5 years ago

I thing you should replace "ๆ" with " ๆ" before calling a cut function.

pepa65 commented 5 years ago

swath -b ' ' -u u,u <<<"เธอเฝ้าแต่คอยที่จะอ่านหนังสือไปเรื่อยๆ" outputs: เธอ เฝ้า แต่ คอย ที่ จะ อ่าน หนังสือ ไป เรื่อยๆ which looks correct.

veer66 commented 5 years ago

swath -b ' ' -u u,u <<<"เธอเฝ้าแต่คอยที่จะอ่านหนังสือไปเรื่อยๆ" outputs: เธอ เฝ้า แต่ คอย ที่ จะ อ่าน หนังสือ ไป เรื่อยๆ which looks correct.

Isn't [เรื่อย, ๆ] easier than [เรื่อยๆ] for further processing?

pepa65 commented 5 years ago

A single non-composable glyph like ๆ is easy to find and process any which way, whether you put a space in front of it or not. I think officially you are supposed to always write it with a space in front, but people don't tend to do that. I guess it depends on your processing, I am fine either way.