public class ViterbiSegment extends WordBasedSegment
config, customDictionary| Constructor and Description |
|---|
ViterbiSegment() |
ViterbiSegment(String customPath) |
ViterbiSegment(String customPath,
boolean cache) |
| Modifier and Type | Method and Description |
|---|---|
DoubleArrayTrie<CoreDictionary.Attribute> |
getDat() |
protected List<Term> |
segSentence(char[] sentence)
给一个句子分词
|
void |
setDat(DoubleArrayTrie<CoreDictionary.Attribute> dat) |
convert, decorateResultForIndexMode, fixResultByRule, generateBiGraph, generateWord, generateWordNet, speechTaggingatomSegment, combineByCustomDictionary, combineByCustomDictionary, combineByCustomDictionary, combineByCustomDictionary, convert, enableAllNamedEntityRecognize, enableCustomDictionary, enableCustomDictionary, enableCustomDictionaryForcing, enableIndexMode, enableIndexMode, enableJapaneseNameRecognize, enableMultithreading, enableMultithreading, enableNameRecognize, enableNumberQuantifierRecognize, enableOffset, enableOrganizationRecognize, enablePartOfSpeechTagging, enablePlaceRecognize, enableTranslatedNameRecognize, mergeNumberQuantifier, quickAtomSegment, seg, seg, seg2sentence, seg2sentence, simpleAtomSegmentpublic ViterbiSegment()
public ViterbiSegment(String customPath)
customPath - 自定义字典路径(绝对路径,多词典使用英文分号隔开)public ViterbiSegment(String customPath, boolean cache)
customPath - customPath 自定义字典路径(绝对路径,多词典使用英文分号隔开)cache - 是否缓存词典public DoubleArrayTrie<CoreDictionary.Attribute> getDat()
public void setDat(DoubleArrayTrie<CoreDictionary.Attribute> dat)
protected List<Term> segSentence(char[] sentence)
SegmentsegSentence in class Segmentsentence - 待分词句子Copyright © 2014–2021 码农场. All rights reserved.