Entity Insertion in Multilingual Linked Corpora: The Case of W ikipedia (2024)

Abstract: Links are a fundamental part of information networks, turning isolated pieces of knowledge into a network of information that is much richer than the sum of its parts. However, adding a new link to the network is not trivial: it requires not only the identification of a suitable pair of source and target entities but also the understanding of the content of the source to locate a suitable position for the link in the text. The latter problem has not been addressed effectively, particularly in the absence of text spans in the source that could serve as anchors to insert a link to the target entity. To bridge this gap, we introduce and operationalize the task of entity insertion in information networks. Focusing on the case of Wikipedia, we empirically show that this problem is, both, relevant and challenging for editors. We compile a benchmark dataset in 105 languages and develop a framework for entity insertion called LocEI (Localized Entity Insertion) and its multilingual variant XLocEI. We show that XLocEI outperforms all baseline models (including state-of-the-art prompt-based ranking with LLMs such as GPT-4) and that it can be applied in a zero-shot manner on languages not seen during training with minimal performance drop. These findings are important for applying entity insertion models in practice, e.g., to support editors in adding links across the more than 300 language versions of Wikipedia.

## introduction from digital encyclopedias and blogs to knowledge graphs, knowledge on the web is organized as a network of interlinked entities and their descriptions. however, online knowledge is not static: new webpages are created, and existing pages are updated almost every day. while there exists substantial support for content creation (e.g. via translation @xcite or generative ai tools shao et al. (2024)), adding new knowledge not only requires creating content but also integrating it into the existing knowledge structure. the latter usually leaves editors with the time-consuming task of reading lengthy webpages to identify a relevant text span for inserting an entity that is not yet mentioned on the page. thus, to support editors in effectively integrating entities in multilingual linked corpora on the web, we introduce the task of entity insertion. ## related work in this section, we review works that overlap closely with our study (cf. appx. a for details). entity linking. previous work has framed entity insertion as an entity linking problem @xcite @xcite @xcite , where the goal is to assign a unique identity to entities mentioned in the text. the task of entity linking is composed of two sub-tasks: named entity recognition (ner) and named entity dis-ambiguation (ned). most research @xcite @xcite into entity linking solves first the ner problem, in which the task is to find candidate mentions for named entities in the source article. however, there is recent work @xcite exploring the problem in reverse order, first solving ned by finding target entities related to the source article and then ner searching only for mentions for the found targets. when the mention is present, the task of entity insertion is similar to ner @xcite , as both tasks can be solved by searching for mentions in the text. however, entity insertion is a more general task as it allows for the mention of the target entity to not yet be present in the text. in this case, the goal is to exploit the context information to find the text span most related to the target entity. ner modules @xcite are designed to search for the most related mentions, and thus, they are not applicable in scenarios where the mentions are not yet available. entity tagging. @xcite introduced this task as a relaxed form of entity linking. an entity tagging model is only tasked with determining the entities present in the text and does not need to find the exact mentions of the entities. however, even though the model is not tasked with extracting an entity's mention, the task of entity tagging still assumes that the text contains some mention of the entity, which distinguishes it from entity insertion. link the wiki. @xcite ran a track at inex 2008 with two tasks: file-to-file link discovery and mention-to-bep (best entry point) link discovery. file-to-file link discovery is a documentlevel task that can be framed as a link prediction task in networks, where the wikipedia articles act as nodes and the links act as edges. the mentionto-bep task is an entity linking task with anchor prediction, where the two-part goal is to find mentions in the source article pointing to other articles, and finding the best point of entry (the anchor) in the target file. this task has more recently resurfaced as an anchor prediction task @xcite . passage ranking. transformer-based models have revolutionized passage ranking by enhancing semantic understanding beyond traditional lexical methods like bm25 @xcite . bert demonstrated early success by leveraging contextualized embeddings for re-ranking (nogueira and cho, 2019), leading to innovations like colbert @xcite , which uses a dual-encoder architecture for more efficient retrieval. recent models such as t5 @xcite and electra @xcite further refine ranking by employing advanced pre-training techniques. building on top of this work, @xcite employ knowledge graphs to exploit background information to better rank passages. however, such graph-based approaches are not suited for large-scale, highly dynamic graphs (such as wikipedia), as the cost of recomputing all the embeddings associated with the graph is too high. finally, while large language models have been shown to be the state of the art for passage ranking @xcite , despite their performance they are impractical at the web-scale owing to exorbitantly high computational costs. ## task formulation let e src be a source entity and e tgt be a target entity. let x src be the textual content of the article corresponding to e src . the text can be partitioned into a set of (potentially overlapping) text spans, x @xmath0, ..., x m }, where m is the number of text spans in the article. entity insertion is the task of selecting the most relevant span x * to insert the target entity e tgt . formally, ## data we constructed a new multilingual dataset for studying entity insertion in wikipedia. the dataset consists of links extracted from all wikipedia articles, each link's surrounding context, and additional article-level meta-data (such as titles, wikidata qids, and lead paragraphs). overall, the dataset contains 958m links from 49m articles in 105 languages. the largest language is english (en), with 166.7m links from 6.7m articles, and the smallest language is xhosa (xh), with 2.8k links from 1.6k articles (cf. appendix b for details). fig. 3 provides an overview of our data processing pipeline. the data processing was done in two steps. we first extracted all the links from the 2023-10-01 snapshot. next, we found all the links added in the time between 2023-10-01 and 2023-11-01. existing links. we extract the content of all articles from their html version using the corresponding snapshot of the enterprise html dumps (wmf, 2010b). we removed articles without a lead paragraph and a wikidata qid. for each article, we consider all internal links in the main article body (ignoring figures, tables, notes, and captions) together with their surrounding context. we removed all the links where either the source or the target article was one of the removed articles and we dropped all the self-links. added links. we extract the set of added links by comparing existing links in snapshots from consecutive months. we apply the same procedure as above to each snapshot, respectively, and take the difference of the two sets to identify the links that exist in the second month but not in the first. to identify the article version in which the link was added, we go through the articles' full revision history available in the wikimedia xml dumps @xcite . next, we identify the two versions of an article before and after the link addition and download the corresponding html. comparing the two html versions, we extract the content modifications made by the editor when adding the link, and categorize them into five entity insertion scenarios. (1) text_present: the link was added by hyperlinking an existing mention; (2) missing_mention: the link was added by adding the mention for a new entity (and potentially some additional content) into an existent sentence; (3) missing_sentence: the link was added by writing a new sentence to complement the already existing text and hyperlinking part of the sentence at the same time; (4) missing_span: an extension of the previous category, where the editors added a span of multiple sentences; and (5) missing_section: the link was added in a section that did not exist in the previous version of the article. we provide examples ( ## entity insertion with locei fig. 4 presents an overview of locei. our model ( § 5.1) is composed of a transformer-based encoder that jointly encodes the target entity as well as the candidate spans in the source entity, and a multilayer perceptrion (mlp) trained via a listwise objective capable of ranking candidates based on their relevance to the target. we introduce a novel data augmentation strategy that closely mimics real-world entity insertion scenarios ( § 5.2), a knowledge injection module to incorporate external knowledge about the entities ( § 5.3), and the multilingual variant xlocei ( § 5.4). ## experiments all the resources required to reproduce the experiments in this paper are available at https://github. com/epfl-dlab/multilingual-entity-insertion .