Seth Woolley's Man Viewer

wn(1) - wn - command line interface to WordNet lexical database - man 1 wn

([section] manual, -k keyword, -K [section] search, -f whatis)
man plain no title

WN(1WN)                     WordNettm User Commands                    WN(1WN)



NAME
       wn - command line interface to WordNet lexical database

SYNOPSIS
       wn  [  searchstr  ]  [ -h] [ -g ] [ -a ] [ -l ] [ -o ] [ -s ] [ -n# ] [
       search_option... ]

DESCRIPTION
       wn() provides a command line interface to the WordNet database,  allow-
       ing  synsets and relations to be displayed as formatted text.  For each
       word, different searches are provided, based on syntactic category  and
       pointer types.  Although only base forms of words are usually stored in(1,8)
       WordNet, users(1,5) may search for inflected forms.  A morphological process
       is  applied  to the search string(3,n) to generate a form that is present in(1,8)
       WordNet.

       The command line interface is often  useful  when  writing  scripts  to
       extract  information from the WordNet database.  Post-processing of the
       output with  various  scripting  tools  can  reformat  the  results  as
       desired.

OPTIONS
       -h             Print help text before search results.

       -g             Display textual glosses associated with synsets.

       -a             Display lexicographer file(1,n) information.

       -o             Display synset offset of each synset.

       -s             Display each word's sense numbers in(1,8) synsets.

       -l             Display  the  WordNet  copyright notice, version(1,3,5) number,
                      and license.

       -n#            Perform search on sense number # only.

       -over          Display overview of all senses of searchstr in(1,8) all  syn-
                      tactic categories.

   Search Options
       Note  that  the last letter of search_option generally denotes the part
       of speech that the search applies to: n for nouns, v for verbs,  a  for
       adjectives,  and  r  for  adverbs.   Multiple  searches may be done for
       searchstr with a single  command  by  specifying  all  the  appropriate
       search options.


       -syns(n | v | a | r)
                      Display synonyms and immediate hypernyms of synsets con-
                      taining searchstr.  Synsets  are  ordered  by  estimated
                      frequency  of use.  For adjectives, if(3,n) searchstr is in(1,8) a
                      head synset, the cluster's satellite  synsets  are  dis-
                      played  in(1,8)  place  of  hypernyms.   If searchstr is in(1,8) a
                      satellite synset, its head synset is also displayed.

       -simsv         Display verb synonyms and immediate hypernyms of synsets
                      containing searchstr.  Synsets are grouped by similarity
                      of meaning.

       -ants(n | v | a | r)
                      Display synsets containing antonyms of  searchstr.   For
                      adjectives,  if(3,n) searchstr is in(1,8) a head synset, searchstr
                      has a direct antonym.  The head synset  for  the  direct
                      antonym  is  displayed  along  with the direct antonym's
                      satellite synsets.   If  searchstr  is  in(1,8)  a  satellite
                      synset,  searchstr  has an indirect antonym via the head
                      synset, which is displayed.

       -faml(n | v | a | r)
                      Display familiarity and polysemy information for search-
                      str.

       -hype(n | v)   Recursively  display  hypernym  (superordinate) tree for
                      searchstr (searchstr IS A KIND OF _____ relation).

       -hypo(n | v)   Display immediate hyponyms (subordinates) for  searchstr
                      (_____ IS A KIND OF searchstr relation).

       -tree(n | v)   Display  hyponym (subordinate) tree for searchstr.  This
                      is a recursive search that finds the  hyponyms  of  each
                      hyponym.

       -coor(n | v)   Display  the  coordinates  (sisters) of searchstr.  This
                      search prints the immediate  hypernym  for  each  synset
                      that  contains  searchstr  and  the hypernym's immediate
                      hyponyms.

       -deri(n | v)   Display derivational morphology links between  noun  and
                      verb forms.

       -domn(n | v | a | r)
                      Display domain that searchstr has been classified in.

       -domt(n | v | a | r)
                      Display  all  terms classified as members of the search-
                      str's domain.

       -subsn         Display substance meronyms of searchstr  (HAS  SUBSTANCE
                      relation).

       -partn         Display  part meronyms of searchstr (HAS PART relation).

       -membn         Display member meronyms of searchstr (HAS  MEMBER  rela-
                      tion).

       -meron         Display all meronyms of searchstr (HAS PART, HAS MEMBER,
                      HAS SUBSTANCE relations).

       -hmern         Display meronyms for searchstr tree.  This is  a  recur-
                      sive  search  that  prints all the meronyms of searchstr
                      and all of its hypernyms.

       -sprtn         Display part of holonyms of  searchstr  (PART  OF  rela-
                      tion).

       -smemn         Display member of holonyms of searchstr (MEMBER OF rela-
                      tion).

       -ssubn         Display substance of holonyms of searchstr (SUBSTANCE OF
                      relation).

       -holon         Display  all  holonyms of searchstr (PART OF, MEMBER OF,
                      SUBSTANCE OF relations).

       -hholn         Display holonyms for searchstr tree.  This is  a  recur-
                      sive  search  that  prints all the holonyms of searchstr
                      and all of each holonym's holonyms.

       -entav         Display entailment relations of searchstr.

       -framv         Display applicable verb sentence frames for searchstr.

       -causv         Display cause to relations of searchstr.

        -pert(a | r)  Display pertainyms of searchstr.

        -attr(n | a)  Display adjective values for  noun  attribute,  or  noun
                      attributes of adjective values.

       -grep(n | v | a | r)
                      List compound words containing searchstr as a substring.

SEARCH RESULTS
       The results of a search are written to the standard output.   For  each
       search,  the output consists a one line description of the search, fol-
       lowed by the search results.

       All searches other than -over  list  all  senses  matching  the  search
       results  in(1,8) the following general format.  Items enclosed in(1,8) italicized
       square brackets ([ ... ]) may not be present.

              One line listing  the  number  of  senses  matching  the  search
              request.

              Each sense matching the search requested displayed as follows:

                   Sense n
                   [{synset_offset}] [<lex_filename>]  word1[#sense_number][,  word2...]

              Where n is the sense number of the search word, synset_offset is
              the byte offset of the synset in(1,8) the data.pos file(1,n) corresponding
              to the syntactic category, lex_filename is the name of the lexi-
              cographer file(1,n) that the synset comes from, word1  is  the  first
              word in(1,8) the synset (note that this is not necessarily the search
              word) and sense_number is the WordNet sense number  assigned  to
              the preceding word.  synset_offset, lex_filename, and sense_num-
              ber are generated when the -o, -a, and -s options, respectively,
              are specified.

              The synsets matching the search requested are printed below each
              sense's synset output described above.  Each line of  output  is
              preceded  by  a marker (usually =>), then a synset, formatted as
              described above.  If a search traverses more one  level  of  the
              tree, then successive lines are indented by spaces corresponding
              to its level in(1,8) the hierarchy.  When the -g option is specified,
              synset  glosses  are displayed in(1,8) parentheses at the end of each
              synset.  Each synset is printed on one line.

              Senses are generally ordered from most to least frequently used,
              with  the  most  common  sense  numbered 1.  Frequency of use is
              determined by the number of times a sense is tagged in(1,8) the vari-
              ous  semantic  concordance  texts.  Senses that are not semanti-
              cally tagged follow the ordered senses.  Note that this ordering
              is only an estimate based on usage in(1,8) a small corpus.

              Verb senses can be grouped by similarity of meaning, rather than
              ordered by frequency of  use.   The  -simsv  search  prints  all
              senses that are close(2,7,n) in(1,8) meaning together, with a line of dashes
              indicating the end of a group.  See wngroups(7WN) for a  discus-
              sion of how senses are grouped.

              The  -over  search displays an overview of all the senses of the
              search word in(1,8) all syntactic categories.  The  results  of  this
              search  are  similar  to the -syns search, however no additional
              (ex. hypernym) synsets are displayed,  and  synset  glosses  are
              always  printed.   The senses are grouped by syntactic category,
              and each synset is annotated as described above with synset_off-
              set(7,n,1 builtins),  lex_filename,  and sense_number as dictated by the -o, -a,
              and -s options.  The overview search also indicates how many  of
              the  senses  in(1,8)  each  syntactic category are represented in(1,8) the
              tagged texts.  This is a way for the user to determine whether a
              sense's  sense  number is based on semantic tagging data, or was
              randomly assigned.   For each sense that has  appeared  in(1,8)  such
              texts,  the  number of semantic tags to that sense are indicated
              in(1,8) parentheses after the sense number.

              If a search cannot be performed on some senses of searchstr, the
              search results are headed by a string(3,n) of the form:
                   X of Y senses of searchstr

              The output of the -deri search shows word forms that are morpho-
              logically related to searchstr. Each word form pointed  to  from
              searchstr is displayed, preceded by RELATED TO-> and the syntac-
              tic category of the link(1,2), followed, on the  next  line,  by  its
              synset.  Printed after the word form is #n where n indicates the
              WordNet sense number of the term(5,7) pointed to.

              The -domn and -domt searches show the domain that a  synset  has
              been  classified  in(1,8) and, conversely, all of the terms that have
              been assigned to a specific domain.  A domain is either a  CATE-
              GORY,  REGION  or  USAGE,  as  reflected in(1,8) the specific pointer
              character stored in(1,8) the database, and displayed in(1,8)  the  output.
              A  -domn  search  on  a term(5,7) shows the domain, if(3,n) any, that each
              synset containing searchstr has been classified in.  The  output
              display  shows the domain type (CATEGORY, REGION or USAGE), fol-
              lowed by the syntactic category of the  domain  synset  and  the
              terms  in(1,8) the synset.  Each term(5,7) is followed by #n where n indi-
              cates the WordNet  sense  number  of  the  term.   The  converse
              search,  -domt,  shows  all of the synsets that have been placed
              into the domain searchstr, with analogous markers.

              When -framv is  specified,  sample  illustrative  sentences  and
              generic  sentence frames are displayed.  If a sample sentence is
              found, the base form of search is substituted into the sentence,
              and  it  is  printed  below  the  synset,  preceded with the EX:
              marker.  When no sample sentences are found,  the  generic  sen-
              tence frames are displayed.  Sentence frames that are acceptable
              for all words in(1,8) a synset are preceded by the marker *>.   If  a
              frame  is acceptable for the search word only, it is preceded by
              the marker =>.

              Search results for adjectives are slightly different from  those
              for  other  parts  of speech.  When an adjective is printed, its
              direct antonym, if(3,n) it has one, is also printed  in(1,8)  parentheses.
              When  searchstr  is  in(1,8)  a head synset, all of the head synset's
              satellites are also displayed.  The position of an adjective  in(1,8)
              relation  to the noun may be restricted to the prenominal, post-
              nominal or predicative position.  Where present, these  restric-
              tions are noted in(1,8) parentheses.

              When  an  adjective  is a participle of a verb, the output indi-
              cates the verb and displays its synset.

              When an adverb is derived from an adjective, the specific adjec-
              tival sense on which it is based is indicated.

              The  morphological  transformations performed by the search code
              may result in(1,8) more than one word to search for.   WordNet  auto-
              matically  performs  the  requested search on all of the strings
              and returns the results grouped by word.  For example, the  verb
              saw  is both the present tense of saw and the past tense of see.
              When passed searchstr saw, WordNet performs the  desired  search
              first  on  saw and next on see, returning the list of saw senses
              and search results, followed by those for see.

EXIT STATUS
       wn() normally exits with the number of senses displayed.  If searchword
       is not found in(1,8) WordNet, it exits with 0.

       If  the  WordNet  database  cannot be opened, an error(8,n) messages is dis-
       played and wn() exits with -1.

ENVIRONMENT VARIABLES
       WNHOME              Base  directory  for  WordNet.   Unix  default   is
                           /usr/local/WordNet-2.0,  Windows default is C:\Pro-
                           gram Files\WordNet\2.0.

       WNSEARCHDIR         Directory in(1,8) which the WordNet  database  has  been
                           installed.   Unix  default  is WNHOME/dict, Windows
                           default is WNHOME\dict.

FILES
       All files are in(1,8) the directory WNSEARCHDIR.

       index.pos           database index files (Unix)

       pos.idx             database index files (Windows)

       data.pos            database data files (Unix)

       pos.dat             database data files (Windows)

       *.vrb               files of sentences illustrating the use of verbs

       pos.exc             morphology exception lists

SEE ALSO
       wnintro(1,3,5,7)(1WN),  wnb(1WN),  wnintro(1,3,5,7)(3WN),  lexnames(5WN),   senseidx(5WN)
       wndb(5WN), wninput(5WN), morphy(7WN), wngloss(7WN), wngroups(7WN).

BUGS
       Please report bugs to wordnet@princeton.edu.



WordNet 2.0                        July 2003                           WN(1WN)

References for this manual (incoming links)