Class: Raingrams::HexagramModel

Inherits:
MultigramModel show all
Defined in:
lib/raingrams/hexagram_model.rb

Direct Known Subclasses

OpenVocabulary::HexagramModel

Instance Attribute Summary

Attributes inherited from MultigramModel

#prefix_frequency

Attributes inherited from Model

#convert_abbrev, #convert_acronyms, #frequency, #ignore_case, #ignore_phone_numbers, #ignore_punc, #ignore_references, #ignore_urls, #ngram_size, #probability

Instance Method Summary collapse

Methods inherited from MultigramModel

#build, #clear, #common_fragment_probability, #common_ngrams_from_fragment, #common_ngrams_from_sentence, #common_ngrams_from_text, #common_ngrams_from_words, #common_sentence_probability, #common_text_probability, #fragment_probability, #grams_following, #grams_preceeding, #ngrams_following, #ngrams_from_fragment, #ngrams_from_sentence, #ngrams_from_text, #ngrams_from_words, #ngrams_postfixed_by, #ngrams_preceeding, #ngrams_prefixed_by, #sentence_probability, #similar_fragment_probability, #similar_sentence_probability, #similar_text_probability, #text_probability, #train_with_ngram, #train_with_sentence, #train_with_text

Methods inherited from Model

#clear, #each_ngram, #has_ngram?, #ngrams, #ngrams_ending_with, #ngrams_starting_with, #ngrams_with, #parse_sentence, #parse_text, #probabilities_for, #probability_of_gram, #probability_of_ngram, #probability_of_ngrams, #train_with_ngram, #train_with_ngrams, #vocabulary, #within_vocabulary?

Constructor Details

#initialize(opts = {}, &block) ⇒ HexagramModel

Returns a new instance of HexagramModel.



6
7
8
9
10
# File 'lib/raingrams/hexagram_model.rb', line 6

def initialize(opts={},&block)
  opts[:ngram_size] = 6

  super(opts,&block)
end