Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type DictTokenizer ¶
Tokenizes Chinese text using a dictionary
func (DictTokenizer) Tokenize ¶
func (tokenizer DictTokenizer) Tokenize(fragment string) []TextToken
Tokenizes a Chinese text string into words and other terms in the dictionary. If the terms are not found in the dictionary then individual characters will be returned. Compares left to right and right to left greedy methods, taking the one with the least tokens.
Click to show internal directories.
Click to hide internal directories.