FreeLing  4.0
Public Member Functions | Private Types | Private Member Functions | Private Attributes
freeling::mention_detector Class Reference

The class mention_detector implements a rule-based entity mention detector. More...

#include <mention_detector.h>

List of all members.

Public Member Functions

 mention_detector (const std::wstring &, const std::wstring &lang=L"")
 Constructor.
 ~mention_detector ()
 Destructor.
std::map< std::wstring,
freeling::regexp > & 
get_config_labels ()
 get the labels of the configuration of the mention detector
void detect (const document &, std::vector< mention > &)
 Detects entity mentions from parse tree nodes of sentences, and fills given vector.

Private Types

enum  subordinateType {
  NONE, REL_CLAUSE, ESSENTIAL, PRE_NON_ESSENTIAL,
  NON_ESSENTIAL
}

Private Member Functions

void candidates (int, paragraph::const_iterator, int &, sentence::const_iterator &, int &, parse_tree::const_iterator, std::vector< mention > &, subordinateType &) const
 Recursively finds all the mentions from a parse_tree NPs, coordinated NPs, pronouns, proper names and NEs.
void discard_mentions (std::vector< mention > &) const
 Discard some mentions with the same head.
void add_mention (const mention &, std::vector< mention > &, int &) const
 add a new mention in a vector
void mark_initial_mentions_from (int, std::vector< mention > &) const
 Mark those mentions which are the initial ones in their sentence.

Private Attributes

std::map< std::wstring,
freeling::regexp
_Labels
 Configuration options.
std::set< std::wstring > _No_heads
bool _Reduce_mentions
std::wstring _Language
 Language.

Detailed Description

The class mention_detector implements a rule-based entity mention detector.


Member Enumeration Documentation

Enumerator:
NONE 
REL_CLAUSE 
ESSENTIAL 
PRE_NON_ESSENTIAL 
NON_ESSENTIAL 

Constructor & Destructor Documentation

freeling::mention_detector::mention_detector ( const std::wstring &  ,
const std::wstring &  lang = L"" 
)

Constructor.

Destructor.


Member Function Documentation

void freeling::mention_detector::add_mention ( const mention ,
std::vector< mention > &  ,
int  
) const [private]

add a new mention in a vector

void freeling::mention_detector::candidates ( int  ,
paragraph::const_iterator  ,
int ,
sentence::const_iterator &  ,
int ,
parse_tree::const_iterator  ,
std::vector< mention > &  ,
subordinateType  
) const [private]

Recursively finds all the mentions from a parse_tree NPs, coordinated NPs, pronouns, proper names and NEs.

void freeling::mention_detector::detect ( const document ,
std::vector< mention > &   
)

Detects entity mentions from parse tree nodes of sentences, and fills given vector.

void freeling::mention_detector::discard_mentions ( std::vector< mention > &  ) const [private]

Discard some mentions with the same head.

get the labels of the configuration of the mention detector

void freeling::mention_detector::mark_initial_mentions_from ( int  ,
std::vector< mention > &   
) const [private]

Mark those mentions which are the initial ones in their sentence.


Member Data Documentation

std::map<std::wstring, freeling::regexp> freeling::mention_detector::_Labels [private]

Configuration options.

std::wstring freeling::mention_detector::_Language [private]

Language.

std::set<std::wstring> freeling::mention_detector::_No_heads [private]

The documentation for this class was generated from the following file: