|
NAMEWordNet::Similarity::GlossFinder - module to implement gloss finding methods for WordNet::Similarity measures of semantic relatedness (specifically, lesk and vector)SYNOPSISuse WordNet::QueryData; my $wn = WordNet::QueryData->new; defined $wn or die "Construction of WordNet::QueryData failed"; use WordNet::Similarity::GlossFinder; my $obj = WordNet::Similarity::GlossFinder->new ($wn); my ($err, $errString) = $obj->getError (); $err and die $errString; my $wps1 = 'england#n#1'; my $wps2 = 'winston_churchill#n#1'; # get the glosses of these two synsets, since we are not using a # configuation file to specify relations, we will only get the # immediate glosses of the two wps entries. The default weight and # relation appear in $weight and $relation - these can be modified # via a configuration file. my ($wps1gloss, $wps2gloss, $weight, $relation ) = $obj -> getSuperGlosses ($wps1, $wps2); print "$wps1gloss->[0]\n"; print "$wps2gloss->[0]\n"; print "$weight->[0]\n"; print "$relation->[0]\n"; DESCRIPTIONIntroductionThis class is derived from (i.e., is a sub-class of) WordNet::Similarity. Two of the measures of similarity, provided in this package, viz. WordNet::Similarity::lesk and WordNet::Similarity::vector deal with WordNet glosses. This module provides methods for easy access to the required glosses.MethodsThis module inherits all the methods of WordNet::Similarity. Additionally, the following methods are also defined.Public methods
Private Methods
DiscussionMany of the methods in this module can work with either offsets or wps strings internally. There are several interesting consequences of each mode.
AUTHORSTed Pedersen, University of Minnesota Duluth tpederse at d.umn.edu Siddharth Patwardhan, University of Utah, Salt Lake City sidd at cs.utah.edu BUGSNone.SEE ALSOWordNet::Similarity(3) WordNet::Similarity::vector(3) WordNet::Similarity::lesk(3)COPYRIGHTCopyright (c) 2005, Ted Pedersen and Siddharth PatwardhanThis program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 2 of the License, or (at your option) any later version. This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with this program; if not, write to The Free Software Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. Note: a copy of the GNU General Public License is available on the web at <http://www.gnu.org/licenses/gpl.txt> and is included in this distribution as GPL.txt.
Visit the GSP FreeBSD Man Page Interface. |