我正在尝试在我正在处理的 ruby 项目中使用 Ankusa (https://github.com/livingsocial/ankusa) gem。
我在安装了 ankusa gem 的情况下运行下面的代码,但仍然出现错误:未初始化的常量 Ankusa::MemoryStorage (NameError)
require 'rubygems'
require 'ankusa'
require 'ankusa/hbase_storage'
storage = Ankusa::MemoryStorage.new
c = Ankusa::NaiveBayesClassifier.new storage
c.train :spam, "This is some spammy text"
c.train :good, "This is not the bad stuff"
puts c.classify "This is some spammy text"
puts c.classifications "This is some spammy text"
puts c.log_likelihoods "This is some spammy text"
puts c.classnames
storage.close
任何帮助将不胜感激。