kham-core 0.2.0

Pure Rust Thai word segmentation engine — no_std compatible
Documentation
1
2
3
4
5
6
7
8
9
10
11
12
13
# Normalization test cases — all inputs are already in canonical form.
# Malformed cases (สระลอย reorder, วรรณยุกต์ dedup) are tested in code
# using explicit Unicode escapes since text editors normalize on save.
# Format: input|tok1|tok2|...
# These verify that normalize() is idempotent on clean Thai text.
กินข้าว|กิน|ข้าว
สวัสดีชาวโลก|สวัสดี|ชาว|โลก
ธนาคารแห่งนั้น|ธนาคาร|แห่ง|นั้น
น้ำใจดี|น้ำ|ใจ|ดี
ข้าวต้มร้อน|ข้าว|ต้ม|ร้อน
ใจดีมีเมตตา|ใจ|ดี|มี|เมตตา
ไฟฟ้าดับกลางคืน|ไฟ|ฟ้า|ดับ|กลาง|คืน
ห้องน้ำสะอาด|ห้อง|น้ำ|สะ|อาด