Entity Recognition

What is Entity Recognition?

Entity Recognition, also known as Named Entity Recognition (NER), is a frequently used task in data science and natural language processing. It involves identifying and classifying key information (entities) in text into predefined categories such as names of persons, organizations, locations, expressions of times, quantities, monetary values, percentages, etc.

Importance in Political Intelligence

In the context of open-source political intelligence, entity recognition helps in extracting relevant information from vast amounts of political data. This can include identifying political figures, organizations, events, and locations from news articles, social media, and other sources.

Using Flair’s NER Model

We use the Flair model for English NER, specifically the ner-english-ontonotes-fast model. This model is based on Flair embeddings and LSTM-CRF and predicts 18 tags with an F1-Score of 89.3 (Ontonotes).

As this is a microservice, we can use basically any model for NER. This model was chosen for its wide array of possible entities. If you want to change the NER model, the Pydantic Models for the Entities and the functions that save articles in the postgres service need to be modified.

Predicted Tags

TagMeaning
CARDINALcardinal value
DATEdate value
EVENTevent name
FACbuilding name
GPEgeo-political entity
LANGUAGElanguage name
LAWlaw name
LOClocation name
MONEYmoney name
NORPaffiliation
ORDINALordinal value
ORGorganization name
PERCENTpercent value
PERSONperson name
PRODUCTproduct name
QUANTITYquantity value
TIMEtime value
WORK_OF_ARTname of work of art