Open maokitty opened 6 years ago
JiebaSegmenter.process 的这部分代码看上去词典是否包含都不影响分词结果,为啥这么写呢?
if (wordDict.containsWord(paragraph.substring(i, i + 1))) tokens.add(new SegToken(paragraph.substring(i, i + 1), offset, ++offset)); else tokens.add(new SegToken(paragraph.substring(i, i + 1), offset, ++offset));
JiebaSegmenter.process 的这部分代码看上去词典是否包含都不影响分词结果,为啥这么写呢?