Is this you? As a journalist, you can create a free Muck Rack account to customize your profile, list your contact preferences, and upload a portfolio of your best work.
Claim your profile
Articles by Return Options.Stream
【ElasticSearch】ES自动补全查询与Java接口实现_es 自动补全_-代号9527的博客-CSDN博客
自动补全就是当用户在搜索框输入字符时,我们应该提示出与该字符有关的搜索项。 要实现根据字母做补全,就必须对文档按照拼音分词。GitHub上有相关插件,地址:https://github.com/medcl/elasticsearch-analysis-pinyin,下载和ES对应的版本。 安装步骤: 解压 上传到虚拟机中,elasticsearch的plugin目录 docker volume ls docker inspect volumeXXX 重启elasticsearch的容器 docker restar es 测试 但上面的拼音分词器也有很明显的缺陷,那就是没有进行词条切割,且汉字没了。 ES的分词器由三部分组成: 举个例子: 在创建索引库时, 可以通过settings来配置自定义的analyzer(分词器): PUT /test { "settings": { "analysis": { "analyzer": { // 自定义分词器 "my_analyzer": { // 分词器名称 "tokenizer": "ik_max_word", "filter":...
Show More
loading
Actions
Is this you?
As a journalist, you can create a free Muck Rack account to customize your profile, list your contact preferences, and upload a portfolio of your best work.Get in touch with Return
Contact Return, search articles and posts on X, monitor coverage, and track replies from one place.
Learn more about Muck Rack