Sha256: 86e3ca145fc1aa3ba86953e4083c77a7d596181807b987ad2e6679997204239e
Contents?: true
Size: 330 Bytes
Versions: 2
Compression:
Stored size: 330 Bytes
Contents
require "ruby-spacy" require "terminal-table" nlp = Spacy::Language.new("en_core_web_sm") doc = nlp.read("Where are you?") puts "Morph features of the third word: " + doc[2].morph.to_s puts "POS of the third word: " + doc[2].pos # Morph features of the third word: Case=Nom|Person=2|PronType=Prs # POS of the third word: PRON
Version data entries
2 entries across 2 versions & 1 rubygems
Version | Path |
---|---|
ruby-spacy-0.1.4.1 | examples/linguistic_features/rule_based_morphology.rb |
ruby-spacy-0.1.4 | examples/linguistic_features/rule_based_morphology.rb |