Module: nlp/dictionary

dictionary is an interface to the oxford dictionary API, to get meanings, synonyms and antonyms of the words.

Example

var dictionary = require('dictionary.js');
dictionary("hey", function(data) {
		console.log(JSON.stringify(data));
});

Methods


<inner> getAlterWords(word, callback)

Gets Synonyms and Antonyms of the word sent.
Parameters:
Name Type Description
word String The word whose alternatives are needed.
callback function The function is called as soon as the call to Oxford completes. The single callback is the alternate words received from Oxford.

<inner> getDefinition(word, callback)

Gets meaning and other information of the word sent.
Parameters:
Name Type Description
word String The word whose info is needed.
callback function The function is called as soon as the call to Oxford completes. The single callback is the alternate words received from Oxford.