Class: NHKore::TinySplitter
Overview
Instance Attribute Summary collapse
Instance Method Summary collapse
- #end_split(str) ⇒ Object
-
#initialize ⇒ TinySplitter
constructor
A new instance of TinySplitter.
Methods inherited from Splitter
Constructor Details
#initialize ⇒ TinySplitter
Returns a new instance of TinySplitter.
64 65 66 67 68 69 70 |
# File 'lib/nhkore/splitter.rb', line 64 def initialize(*) require 'tiny_segmenter' super @tiny = TinySegmenter.new end |
Instance Attribute Details
#tiny ⇒ Object
62 63 64 |
# File 'lib/nhkore/splitter.rb', line 62 def tiny @tiny end |
Instance Method Details
#end_split(str) ⇒ Object
72 73 74 |
# File 'lib/nhkore/splitter.rb', line 72 def end_split(str) return @tiny.segment(str,ignore_punctuation: true) end |