Merge branch 'master' of github.com:medcl/elasticsearch-analysis-ik

This commit is contained in:
medcl 2019-10-07 19:01:51 +08:00
commit 5f53f1a5bf
2 changed files with 3 additions and 3 deletions

View File

@ -63,7 +63,7 @@ curl -XPOST http://localhost:9200/index/_mapping -H 'Content-Type:application/js
"content": {
"type": "text",
"analyzer": "ik_max_word",
"search_analyzer": "ik_max_word"
"search_analyzer": "ik_smart"
}
}

View File

@ -268,13 +268,13 @@ class AnalyzeContext {
while(l != null){
this.results.add(l);
//字典中无单字但是词元冲突了切分出相交词元的前一个词元中的单字
int innerIndex = index + 1;
/*int innerIndex = index + 1;
for (; innerIndex < index + l.getLength(); innerIndex++) {
Lexeme innerL = path.peekFirst();
if (innerL != null && innerIndex == innerL.getBegin()) {
this.outputSingleCJK(innerIndex - 1);
}
}
}*/
//将index移至lexeme后
index = l.getBegin() + l.getLength();