def add_item(item, *categories, &block)
      clean_word_hash = Hasher.word_hash((block ? yield(item) : item.to_s),
                                         token_filters: @token_filters)
      if clean_word_hash.empty?
        puts "Input: '#{item}' is entirely stopwords or words with 2 or fewer characters. Classifier-Reborn cannot handle this document properly."
      else
        @items[item] = if @cache_node_vectors
                         CachedContentNode.new(clean_word_hash, *categories)
                       else
                         ContentNode.new(clean_word_hash, *categories)
                       end
        @version += 1
        build_index if @auto_rebuild
      end
    end
def add_item(item, *categories, &block)
      clean_word_hash = Hasher.word_hash((block ? yield(item) : item.to_s),
                                         token_filters: @token_filters)
      if clean_word_hash.empty?
        puts "Input: '#{item}' is entirely stopwords or words with 2 or fewer characters. Classifier-Reborn cannot handle this document properly."
      else
        @items[item] = if @cache_node_vectors
                         CachedContentNode.new(clean_word_hash, *categories)
                       else
                         ContentNode.new(clean_word_hash, *categories)
                       end
        @version += 1
        build_index if @auto_rebuild
      end
    end
Adds an item to the index. item is assumed to be a string, but
 any item may be indexed so long as it responds to #to_s or if
 you provide an optional block explaining how the indexer can
 fetch fresh string data. This optional block is passed the item,
 so the item may only be a reference to a URL or file name.

 For example:
   lsi = ClassifierReborn::LSI.new
   lsi.add_item "This is just plain text"
   lsi.add_item "/home/me/filename.txt" { |x| File.read x }
   ar = ActiveRecordObject.find( :all )
   lsi.add_item ar, *ar.categories { |x| ar.content }