Module: YaCan::Keyphrase

Defined in:
lib/yacan/keyphrase.rb

Defined Under Namespace

Classes: Result

Constant Summary collapse

@@path =
'/KeyphraseService/V1/extract'

Class Method Summary collapse

Class Method Details

.analyze(text) ⇒ Object



4
5
6
7
# File 'lib/yacan/keyphrase.rb', line 4

def analyze(text)
  xml = YaCan::YahooAPI.request(@@path, {'sentence' => text})
  return Result.new(xml)
end

.extract(text) ⇒ Object



9
10
11
# File 'lib/yacan/keyphrase.rb', line 9

def extract(text)
  analyze(text)
end