Module Wordnet


module Wordnet: sig .. end
Module Wordnet: Provides an Ocaml interface to WordNet 2.1 For more info on WordNet refer http://wordnet.princeton.edu/ Author: Ramu Ramamurthy ramu_ramamurthy at yahoo dot com (C) 2006 This software is released under the BSD license


--------The following are Types----------

type posType =
| NOUN
| VER
| ADJ
| ADV
| SAT
parts of speech

type ptrType =
| ANTPTR
| HYPERPTR
| HYPOPTR
| ENTAILPTR
| SIMPTR
| ISMEMBERPTR
| ISSTUFFPTR
| ISPARTPTR
| HASMEMBERPTR
| HASSTUFFPTR
| HASPARTPTR
| MERONYM
| HOLONYM
| CAUSETO
| PPLPTR
| SEEALSO
| PERTPTR
| ATTRIBUTE
| VERBGROUP
| NOMINALIZATIONS
| CLASSIFICATION
| CLASS
| CLASSIF_CATEGORY
| CLASSIF_USAGE
| CLASSIF_REGIONAL
| CLASS_CATEGORY
| CLASS_USAGE
| CLASS_REGIONAL
| INSTANCE
| INSTANCES
| NONEPTR
pointer types
exception WN_Not_found
exception - not found in the Wordnet database
type wordType 
The word type - refers to a word form and the meanings it represents
type senseType 
The sense type - refers to a meaning and the word forms it represents

--------The following are operations on the wordType----------
val isDefined : string -> posType -> bool
check if the pos is applicable for the word form
val getWord : string -> posType -> wordType
get a word given the form and part of speech
Raises WN_Not_found if word form not found
val getWordForm : wordType -> string
get a wordform given the word
val getSenses : wordType -> senseType list
get a list of senses for the word
val getWordPtrs : wordType -> ptrType list
get a list of all pointers that the word has in all senses that contain it
val numTagged : wordType -> int
get the number of senses of word that have been tagged in semantic concordance texts
val getPos : wordType -> posType
get the pos for this word
val isEqualWord : wordType -> wordType -> bool
compare two words for equality
val printWord : wordType -> unit
print details of the word

--------The following are operations on the senseType----------
val getGloss : senseType -> string
get the gloss (description) for this sense
val getPosType : senseType -> posType
get the pos type for this sense
val getWordForms : senseType -> string list
get the word forms mapping to this sense
val getSensePtrs : senseType -> (ptrType * posType * string) list
get all pointers - each pointer has a pos, and a word form for that sense to which the pointer applies For semantic relations, the word is ""
val getPtrSense : ptrType -> senseType -> senseType list
get the senses pointed to by the pointer
val getPtrWordSense : string -> ptrType -> senseType -> senseType list
get the senses pointed to by the pointer for lexical relations for word form
val getWordSenseCount : string -> senseType -> int
how many times has this sense for the word been tagged in concordance texts
val getVerbFrames : string -> senseType -> string list
for verbs, given word and sense, get example frames
val isEqualSense : senseType -> senseType -> bool
compare two senses for equality
val printSense : senseType -> unit
print details of the sense

--------The following are word morphology functions----------
val morph : string -> posType -> string
morphs the word form to its base form

--------The following are utilities------------
val getVersion : unit -> string
get the version of this api