word tokenization for thai language
npm install thai-cut-slimUse the package manager nodejs to install thai-cut-slim.
``bash`
npm i -s thai-cut-slim
`nodejs
const thaiCut = require('thai-cut-slim')
thaiCut.cut('ทดสอบระบบตัดคำ') # returns ['ทดสอบ','ระบบ','ตัด','คำ']
`
`nodejs
const thaiCut = require('thai-cut-slim')
thaiCut.addon(['โห', 'อิอิ'])
thaiCut.cut('ทดสอบเพิ่มคำที่ไม่มีในดิกชันนารี่ เช่น โห อิอิ') # returns [ 'ทดสอบ', 'เพิ่ม', 'คำ', 'ที่', 'ไม่มี', 'ใน', 'ดิกชันนารี', 'เช่น', 'โห', 'อิอิ' ]
``
Please make sure to update tests as appropriate.