relax_tagger Class Reference

The class relax_tagger implements a PoS tagger based on relaxation labelling algorithm. More...

#include <relax_tagger.h>

Inheritance diagram for relax_tagger:
Inheritance graph
[legend]
Collaboration diagram for relax_tagger:
Collaboration graph
[legend]

List of all members.

Public Member Functions

 relax_tagger (const std::string &, int, double, double, bool, unsigned int)
 Constructor, given the constraint file and config parameters.
void analyze (std::list< sentence > &)
 analyze sentences with default options
std::list< sentence > analyze (const std::list< sentence > &)
 analyze sentences and return analyzed copy (for java API)

Private Member Functions

bool CheckCondition (const sentence &, sentence::const_iterator, int, const condition &, std::list< std::list< std::pair< int, int > > > &)
 check a condition of a RuleCG.
bool CheckWordMatchCondition (const std::list< std::string > &, bool, int, sentence::const_iterator, std::list< std::pair< int, int > > &)
 check whether a word matches a simple list of terms.
bool check_possible_matching (const std::string &, word::const_iterator, sentence::const_iterator)
 check whether a word matches one of all possible condition patterns
bool check_match (const std::string &, const std::string &) const
 check a match of two literals, taking into account lemma, tag, wildcards, etc.

Private Attributes

relax solver
 Generic solver instance.
constraint_grammar c_gram
 PoS constraints.
RegEx RE_user

Detailed Description

The class relax_tagger implements a PoS tagger based on relaxation labelling algorithm.

It does so using the generic solver implemented by class relax.


Constructor & Destructor Documentation

relax_tagger::relax_tagger ( const std::string &  ,
int  ,
double  ,
double  ,
bool  ,
unsigned  int 
)

Constructor, given the constraint file and config parameters.


Member Function Documentation

std::list<sentence> relax_tagger::analyze ( const std::list< sentence > &   ) 

analyze sentences and return analyzed copy (for java API)

void relax_tagger::analyze ( std::list< sentence > &   )  [virtual]

analyze sentences with default options

Implements POS_tagger.

bool relax_tagger::check_match ( const std::string &  ,
const std::string &   
) const [private]

check a match of two literals, taking into account lemma, tag, wildcards, etc.

bool relax_tagger::check_possible_matching ( const std::string &  ,
word::const_iterator  ,
sentence::const_iterator   
) [private]

check whether a word matches one of all possible condition patterns

bool relax_tagger::CheckCondition ( const sentence &  ,
sentence::const_iterator  ,
int  ,
const condition ,
std::list< std::list< std::pair< int, int > > > &   
) [private]

check a condition of a RuleCG.

Add to the given constraint& solver-encoded constraint info for the condition

bool relax_tagger::CheckWordMatchCondition ( const std::list< std::string > &  ,
bool  ,
int  ,
sentence::const_iterator  ,
std::list< std::pair< int, int > > &   
) [private]

check whether a word matches a simple list of terms.

Return (via list<pair<int,int>>&) a solver-encoded term for the condition


Member Data Documentation

PoS constraints.

RegEx relax_tagger::RE_user [private]

Generic solver instance.


The documentation for this class was generated from the following file:
Generated on Tue Jul 27 16:29:33 2010 for FreeLing by  doxygen 1.6.3