A Unified MRC Framework for Named Entity Recognition (2020)

Abstract: The task of named entity recognition (NER) is normally divided into nested NER and flat NER depending on whether named entities are nested or not. Models are usually separately developed for the two tasks, since sequence labeling models, the most widely used backbone for flat NER, are only able to assign a single label to a particular token, which is unsuitable for nested NER where a token may be assigned several labels. In this paper, we propose a unified framework that is capable of handling both flat and nested NER tasks. Instead of treating the task of NER as a sequence labeling problem, we propose to formulate it as a machine reading comprehension (MRC) task. For example, extracting entities with the per label is formalized as extracting answer spans to the question “ which person is mentioned in the text ".This formulation naturally tackles the entity overlapping issue in nested NER: the extraction of two overlapping entities with different categories requires answering two independent questions. Additionally, since the query encodes informative prior knowledge, this strategy facilitates the process of entity extraction, leading to better performances for not only nested NER, but flat NER. We conduct experiments on both nested and flat NER datasets.Experiment results demonstrate the effectiveness of the proposed formulation. We are able to achieve a vast amount of performance boost over current SOTA models on nested NER datasets, i.e., +1.28, +2.55, +5.44, +6.37,respectively on ACE04, ACE05, GENIA and KBP17, along with SOTA results on flat NER datasets, i.e., +0.24, +1.95, +0.21, +1.49 respectively on English CoNLL 2003, English OntoNotes 5.0, Chinese MSRA and Chinese OntoNotes 4.0.

## introduction named entity recognition (ner) refers to the task of detecting the span and the semantic category of entities from a chunk of text. the task can be further divided into two sub-categories, nested ner and flat ner, depending on whether entities are nested or not. nested ner refers to a phenomenon that the spans of entities (mentions) are nested, as shown in figure 1 . entity overlapping is a fairly common phenomenon in natural languages. the task of flat ner is commonly formalized as a sequence labeling task: a sequence labeling model @xcite @xcite is trained to assign a single tagging class to each unit within a sequence of tokens. this formulation is unfortunately incapable of handling overlapping entities in nested ner @xcite , where multiple categories need to be assigned to a single token if the token participates in multiple entities. many attempts have been made to reconcile sequence labeling models with nested ner @xcite @xcite @xcite , mostly based on the pipelined systems. however, pipelined systems suffer from the disadvantages of error propagation, long running time and the intensiveness in developing hand-crafted features, etc. inspired by the current trend of formalizing nlp problems as question answering tasks @xcite @xcite , we propose a new framework that is capable of handling both flat and nested ner. instead of treating the task of ner as a sequence labeling problem, we propose to formulate it as a squadstyle @xcite machine reading comprehension (mrc) task. each entity type is characterized by a natural language query, and entities are extracted by answering these queries given the contexts. for example, the task of assigning the per(person) label to " @xcite was born into slavery on the farm of james burroughs" is formalized as answering the question "which person is mentioned in the text?". this strategy naturally tackles the entity overlapping issue in nested ner: the extraction of two entities with different categories that overlap requires answering two independent questions. the mrc formulation also comes with another key advantage over the sequence labeling formulation. for the latter, golden ner categories are merely class indexes and lack for semantic prior information for entity categories. for example, the org(organization) class is treated as a onehot vector in sequence labeling training. this lack of clarity on what to extract leads to inferior performances. on the contrary, for the mrc formulation, the query encodes significant prior information about the entity category to extract. for example, the query "find an organization such as company, agency and institution in the context" encourages the model to link the word "organization" in the query to location entities in the context. additionally, by encoding comprehensive descriptions (e.g., "company, agency and institution") of tagging categories (e.g., org), the model has the potential to disambiguate similar tagging classes. we conduct experiments on both nested and flat ner datasets to show the generality of our approach. experimental results demonstrate its effectiveness. we are able to achieve a vast amount of performance boost over current sota models on nested ner datasets, i.e., +1.28, +2.55, +5.44, +6.37, respectively on ace04, ace05, genia and kbp17, as well as flat ner datasets, i.e., +0.24, +1.95, +0.21, +1.49 respectively on english conll 2003, english ontonotes 5.0, chinese msra, chinese ontonotes 4.0. we wish that our work would inspire the introduction of new paradigms for the entity recognition task. ## conclusion in this paper, we reformalize the ner task as a mrc question answering task. this formalization comes with two key advantages: (1) being capa-ble of addressing overlapping or nested entities;