What does setting the not_analyzed index do when converting the index when using elasticsearch?

What does :index => :not_analyzed if I map it to a field or if I don't add it to the field? I could not find the definition on the github bus home page or on elasticsearch.org website.

Code example:

 class Article < ActiveRecord::Base include Tire::Model::Search include Tire::Model::Callbacks #... mapping do indexes :id, :index => :not_analyzed indexes :title, :analyzer => 'snowball', :boost => 100 end end 
+4
source share
1 answer

Not analyzed means that the field is stored as is, and it is not processed by analysis tools. If you analyze this, you can choose your own analyzer. By default, a standard analyzer is used. This breaks your content in tokens, scribbles them in lower case, removes punctuation, removes English stop words (as, is, are, ...)

I recommend using the analysis API to understand the difference between the analyzers: http://www.elasticsearch.org/guide/reference/api/admin-indices-analyze.html

See the Analysis section for more details: http://www.elasticsearch.org/guide/reference/index-modules/analysis/

+2
source

Source: https://habr.com/ru/post/1443890/


All Articles