你的浏览器禁用了JavaScript, 请开启后刷新浏览器获得更好的体验!
输入关键字进行搜索
搜索:
没有找到相关结果
trycatchfinal
赞同来自:
POST _analyze { "tokenizer": { "type" : "pinyin", "keep_separate_first_letter" : false, "keep_full_pinyin" : true, "keep_original" : true, "limit_first_letter_length" : 16, "lowercase" : true, "keep_joined_full_pinyin":true, "remove_duplicated_term" : true }, "text": "西安" }
{ "tokens" : [ { "token" : "xi", "start_offset" : 0, "end_offset" : 0, "type" : "word", "position" : 0 }, { "token" : "西安", "start_offset" : 0, "end_offset" : 0, "type" : "word", "position" : 0 }, { "token" : "xian", "start_offset" : 0, "end_offset" : 0, "type" : "word", "position" : 0 }, { "token" : "xa", "start_offset" : 0, "end_offset" : 0, "type" : "word", "position" : 0 }, { "token" : "an", "start_offset" : 0, "end_offset" : 0, "type" : "word", "position" : 1 } ] }
要回复问题请先登录或注册
1 个回复
trycatchfinal
赞同来自:
可以配置分词器参数keep_joined_full_pinyin为true,这样索引数据的时候,“西安”的分词结果就包含"xian"