DeSR Dependency Parser

Parser::MeParser Struct Reference

A Parser using a Maximum Entropy classifier. More...

Inheritance diagram for Parser::MeParser:

Inheritance graph
Collaboration diagram for Parser::MeParser:

Collaboration graph

List of all members.

Public Member Functions

 MeParser (char const *modelFile)
void train (SentenceReader *sentenceReader, char const *modelFile)
 Train statistical model using sentences obtained through a sentenceReader, and save the generated model to modelFile.
Sentence * parse (Sentence *sentence)
 Parse the given Sentence sentence.
void revise (SentenceReader *sentenceReader, char const *actionFile=0)
 Produce a revision of a document parses, using either a model or an action file.

Public Attributes

Tanl::Classifier::MaxEnt model


Detailed Description

A Parser using a Maximum Entropy classifier.

Definition at line 55 of file MeParser.cpp.


Member Function Documentation

Sentence * Parser::MeParser::parse ( Sentence *  sentence  )  [virtual]

Parse the given Sentence sentence.

Returns:
a newly allocated
See also:
Sentence.

Implements Parser::Parser.

Definition at line 138 of file MeParser.cpp.

References Parser::ParseState::dispose(), Parser::State::getSentence(), Parser::ParseState::hasNext(), Parser::ParseState::lprob, Parser::ParseState::next(), and Parser::ParseState::transition().

void Parser::MeParser::revise ( SentenceReader *  sentenceReader,
char const *  actionFile = 0 
) [virtual]

Produce a revision of a document parses, using either a model or an action file.

If an actionFile is provided, it must contain a list of actions, one per line, to apply to the parse trees, otherwise the actions to perform revisions are determined using the model.

Reimplemented from Parser::Parser.

Definition at line 213 of file MeParser.cpp.


The documentation for this struct was generated from the following file:
 
Copyright © 2005-2007 G. Attardi. Generated on 13 Aug 2009 by doxygen 1.5.7.1.