Skip to content

plimble/tsplitter

Repository files navigation

tsplitter godoc badge gocover badge Build Status Go Report Card

Thai word break written in GO

Installation

go get -u github.com/plimble/tsplitter

Example

#####Get all words

  func main(){
    dict := NewFileDict("dictionary.txt")
    txt := "ตัดคำไทย"
    words := Split(dict, txt)
    fmt.Println(words.All()) //ตัด, คำ, ไทย
  }

#####Get deduplicate word

  func main(){
    dict := NewFileDict("dictionary.txt")
    txt := "ตัดคำไทย"
    words := Split(dict, txt)
    fmt.Println(words.Known())
    fmt.Println(words.Unknown())
  }

Documentation

###Contributing

If you'd like to help out with the project. You can put up a Pull Request.

Releases

No releases published

Packages

No packages published

Languages