I’d like to get the following behavior:
Stemming. The search is on a database of summaries of California
cases. Things like a search for “thermal image” needs to hit “thermal
Stop words. Searches for “failing to instruct the jury” should come
with hits on a search for “fail to instruct.”
What I tried was:
class StemmedAnalyzer < Ferret::Analysis::Analyzer
def token_stream(field, reader)
class Summary < ActiveRecord::Base
acts_as_ferret(:analyzer => StemmedAnalyzer.new)
But this doesn’t appear to give me either stemming or stopwords. It
give me basic searching (searches for exact keywords without stopwords
searches with stopwords return no results).
I’ve looked through the archives, and I’m still confused. Suggestions?
- James M.