DWQA QuestionsCategory: ProgramElasticsearch uses word segmentation when creating an index
Flying Golden Eagle asked 3 months ago

I want to use elasticsearch in the. Net project PlainElastic.Net Now ordinary search can be used, but I don’t know how to segment words. IK participle has been installed. Please give me some advice on how to use participle when creating index? Thank you so much!

1 Answers
Eapen answered 3 months ago

Configure fields when creating indexes

"analyzer" : "ik_max_word",
"search_analyzer" : "ik_max_word"

that will do

Flying Golden Eagle replied 3 months ago

Thank you for your reply! What’s your name, please PlainElastic.Net Or nest? The C ා side of elasticsearch seems to have only these two.

Eapen replied 3 months ago

We haven’t used the end of. Net, but the API interface of ES is consistent. Different ends only have different languages, but the ES API is the same. As long as you add this configuration and value when creating fields

Flying Golden Eagle replied 3 months ago

Yes, but I was looking for their official English documents, but I couldn’t find them