The mission of the Named Entity Classification module is to assing a class to named entities in the text. It is a Machine-Learning based module, so the classes can be anything the model has been trained to recognize.
When classified, the PoS tag of the word is changed to the label defined in the model.
This module depends on a NER module being applied previously. If no entities are recognized, none can be classified.
Models provided with FreeLing distinguish four classes: Person (tag NP00SP0), Geographical location (NP00G00), Organization (NP00O00), and Others (NP00V00).
If you have an anotated corpus, the models can be trained using the scripts in src/utilities/nec. See the README there and the comments int the script for the details.
The API of the class is the following:
class nec { public: /// Constructor nec(const std::string &, const std::string &); /// Classify NEs in given sentence void analyze(std::list<sentence> &) const; };
The constructor receives two parameters. The first is the tag that the NER module assigned to Named Entities, so the NEC can know which words to classify. The second parameter is the prefix of the configuration files for the model, as described below.