Jet.HMM
Class Retagger

java.lang.Object
  extended byJet.HMM.Retagger

public class Retagger
extends java.lang.Object

class Retagger provides methods for converting Penn part-of-speech tags into Jet part-of-speech tags, and using the result to filter the entries in the Jet lexicon.


Constructor Summary
Retagger()
           
 
Method Summary
static boolean compatible(java.lang.String word, java.lang.String pennPOS, Annotation jetDefn)
          returns true if Penn part-of-speech tag 'pennPOS', as a tag for 'word', is compatible with Jet word definition 'jetDefn'.
static java.lang.String jetToPtbPos(FeatureSet fs)
          given a FeatureSet fs for a Jet lexical constituent (with a 'cat' feature and possibly other features), return a Penn POS consistent with 'fs'.
static void pruneConstit(Document d, Span zone)
          prunes constit annotations using Penn tags (recorded as tagger annotations).
static FeatureSet[] ptbToJetFS(java.lang.String word, java.lang.String pennPOS)
          given an annotation based on Penn tag set, returns an array (possibly empty) of corresponding Jet FeatureSets, with one entry for each possible Jet category and attributes.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

Retagger

public Retagger()
Method Detail

ptbToJetFS

public static FeatureSet[] ptbToJetFS(java.lang.String word,
                                      java.lang.String pennPOS)
given an annotation based on Penn tag set, returns an array (possibly empty) of corresponding Jet FeatureSets, with one entry for each possible Jet category and attributes.


jetToPtbPos

public static java.lang.String jetToPtbPos(FeatureSet fs)
given a FeatureSet fs for a Jet lexical constituent (with a 'cat' feature and possibly other features), return a Penn POS consistent with 'fs'. If several Penn POS's are consistent, one is arbitrarily returned. If none are consistent, 'null' is returned.


pruneConstit

public static void pruneConstit(Document d,
                                Span zone)
prunes constit annotations using Penn tags (recorded as tagger annotations). to do: preferring idioms


compatible

public static boolean compatible(java.lang.String word,
                                 java.lang.String pennPOS,
                                 Annotation jetDefn)
returns true if Penn part-of-speech tag 'pennPOS', as a tag for 'word', is compatible with Jet word definition 'jetDefn'.