See:
          Description

Packages
net.didion.jwnl  
net.didion.jwnl.data Classes for extracting and containing data from the dictionary.
net.didion.jwnl.data.list Lists and associated classes that hold the results of relationship operations.
net.didion.jwnl.data.relationship Tools for finding pointer relationships between words.
net.didion.jwnl.dictionary Classes for acessing dictionary information.
net.didion.jwnl.dictionary.database Classes for accessing databases that contain dictionary information.
net.didion.jwnl.dictionary.file Classes for accessing files that contain dictionary information.
net.didion.jwnl.dictionary.file_manager Classes used by FileBackedDictionary to interface with the filesystem.
net.didion.jwnl.dictionary.morph  
net.didion.jwnl.princeton.data Implementations of DictionaryElementFactory for Princeton's release of WordNet.
net.didion.jwnl.princeton.file Implementations of DictionaryFile used by the various classes of Dictionary to access dictionary files using the naming convention used in Princeton's release of WordNet.
net.didion.jwnl.util Utility classes used by JWNL.
net.didion.jwnl.util.cache Classes used for caching information.
net.didion.jwnl.util.factory Classes involved in reflective creation of JWNL components.

 

JWNL 1.3

JWNL is an API for accessing WordNet-style relational dictionaries. It also provides functionality beyond data access, such as relationship discovery and morphological processing.

Contents:

Changes From Earlier Versions

Starting with version 1.3, JWNL is under a BSD-style license, meaning that it can be used in without restriction. This change can be considered retroactive (i.e. you're okay if you're using earlier versions of JWNL in a commercial software package).

Version 1.3 has changed significantly from earlier versions. So much so, in fact, that it is not backwardly compatible with earlier versions. For this reason, earlier versions will no longer be supported.

The major changes in version 1.3 are:

      Updated classes in the data package to be compatible with WordNet 2.0
      Updated DefaultMorphologicalProcessor to stem additonal suffixes added in WordNet 1.7
      Fixed bugs in FileBackedDictionary and MapBackedDictionary that caused lookups on capitalized terms to return invalid results
      Introduced DatabaseBackedDictionary, plus files to create and populate the WordNet database.
      Removed the util.logging package. JWNL now has a runtime dependancy on Apache commons-logging.
      Fixed several bugs in the relationshp api. The interface for finding relationships is now contained in RelationshipFinder.
      License changed to BSD-style licence.
      Improved the dictionary caching api. AbstractCachingDictionary now has methods to turn caching on and off and change the cache sizes.
      Added getRandomIndexWord method to Dictionary.
      Added new example programs (VocabTrainer, TextInterface) to the utilities package.

Architecture Notes

In developing the architecture for this version of JWNL, the overall design goals were:

  • To make set-up and use of JWNL as simple, and require as little extra code, as possible. A major component of this was making JWNL run off a property file. This resulted in a plugin-style architecture. For example, in the properties file, you specify what type of dictionary interface you want to use via the <dictionary> tag. The class you specify is loaded during initialization and is set as the Dictionary class' singleton instance.
  • To be specific enough that a concrete implemententation could be provided, but general enough that it could be used with any WordNet-like dictionary. A WordNet-like dictionary is one that uses the same concepts and structures (indexes, synsets, exceptions, pointers, etc. In all likelyhood, the attemps made at abstraction of dictionary specific code in this version will not be sufficient for using non-English dictionaries, since other languages may have different syntaxes. But the current architecture does make it easy to adapt the system to new versions of WordNet with little work. This is done by delegating the creation of data objects to a factory class, which, like Dictionary, can be changed simply by changing a line in the property file.
  • To internationalize the text. This is done through the use of property bundles.

    Basic Usage

    Using JWNL is very simple. First, call JWNL.initialize() somewhere in the initialization code of your program.

    Then, just call Dictionary.getInstance() to get the currently installed dictionary. The only dictionary methods you should really ever need to call are lookupIndexWord(), lookupAllIndexWords(), and getIndexWordIterator().

    The other methods you may be interested in RelationshipFinder.findRelationships(), and those in PointerUtils.

    RelationshipFinder.findRelationships() allows you to find relationships of a given type between two words (such as ancestry). Another way of thinking of a relationship is as a path from the source synset to the target synset.

    The methods in PointerUtils allow you to find chains of pointers of a given type. For example, calling PointerUtils.getHypernymTree() on the synset that contains "dog," returns a tree with all its parent synsets ("canine"), and its parents' parents ("carnivore"), etc., all the way to the root synset ("entity").

    Goals for Future Releases

    There are many areas in which JWNL needs improvement:
    • Support for non-english dictionaries
    • A GUI for browsing the dictionary
    • Better documentation, logging, and error messages
    • Frequency of sense use
    As JWNL is now officially an open-source project, you are encouraged to improve JWNL in any of these areas, or any other areas in which you see fit.



  • JWNL homepage.