我已经为它安装了最新版本的 stanfordparser 和 ruby 包装库。尝试使用网站上的一个简单示例对其进行测试时:
vi test.rb:
require "stanfordparser"
preproc =
StanfordParser::DocumentPreprocessor.new
puts
preproc.getSentencesFromString("This
is a sentence. So is this.")
红宝石-rubygems test.rb
This
is
a
sentence
.
So
is
this
.
这真的是一个健全性检查 - 我做错了什么,或者这是解析器或包装器中的错误?