Ruby NLP


ตัว Ruby Linguistics นี่น่าสนใจ ตรงวิธีการใช้ .. คือมัน รูบี๊ รูบี้ น่ะ

ตัวอย่าง:


"box".en.plural    #=> "boxes"
"mouse".en.plural  #=> "mice"
"ruby".en.plural   #=> "rubies"

"book".en.a      #=> "a book"
"article".en.a   #=> "an article"

"runs".en.present_participle    #=> "running"
"eats".en.present_participle    #=> "eating"
"spies".en.present_participle   #=> "spying"

"leaving".en.infinitive         #=> "leave"
"left".en.infinitive            #=> "leave"
"leaving".en.infinitive.suffix  #=> "ing"

"cow".en.quantify( 5 )     #=> "several cows"
"cow".en.quantify( 1005 )  #=> "thousands of cows"

อะไรทำนองนี้

update: (2007.04.02) update “NLP softwares in Ruby” link


Leave a Reply

This site uses Akismet to reduce spam. Learn how your comment data is processed.