---
title: "Inspecting the concept knowledge graph encoded by modern"
description: "A WordNet probe tests which concept hierarchies can be recovered from pretrained word representations and where that reconstruction…"
canonical: "https://research.elamur.ai/free/en/papers/aspillaga-2021-inspecting-concept-knowledge-graph-encoded/"
---
Elamur: [Mova](https://md.mova.elamur.ai/free/en/) · [Parse](https://mova.elamur.ai/free/en/parse/) · [Dictionary](https://md.dictionary.elamur.ai/free/en/) · [Translate](https://md.translate.elamur.ai/free/en/) · **Research** · [Gali](https://md.gali.elamur.ai/free/en/) · [MCP](https://mcp.elamur.ai/) · [Locations](https://md.locations.elamur.ai/free/en/) · [Weather](https://md.weather.elamur.ai/free/en/) · [Constitution](https://md.constitution.elamur.ai/)

[Elamur Research](https://md.research.elamur.ai/free/en/) · [this page in HTML](https://research.elamur.ai/free/en/papers/aspillaga-2021-inspecting-concept-knowledge-graph-encoded/)

[Elamur Research](https://md.research.elamur.ai/free/en/) / [papers](https://md.research.elamur.ai/free/en/papers/) / [2021](https://md.research.elamur.ai/free/en/papers/2021/) / Inspecting the concept knowledge graph encoded by modern language models

# Inspecting the concept knowledge graph encoded by modern language models

Paper · 2021 · Carlos Aspillaga, Marcelo Mendoza and Alvaro Soto

**Authors:** [Carlos Aspillaga](https://md.research.elamur.ai/free/en/authors/carlos-aspillaga/), [Marcelo Mendoza](https://md.research.elamur.ai/free/en/authors/marcelo-mendoza/) and [Alvaro Soto](https://md.research.elamur.ai/free/en/authors/alvaro-soto/) · **Year:** 2021 · **Venue:** Findings of the Association for Computational Linguistics: ACL-IJCNLP 2021 · **Licence:** [CC BY 4.0 (ACL Anthology)](https://creativecommons.org/licenses/by/4.0/)

[Cited by **9** papers in our library of more than 163,000 papers whose bibliographies we read](https://md.research.elamur.ai/free/en/papers/aspillaga-2021-inspecting-concept-knowledge-graph-encoded/cited-by/) · Findings of the Association for Computational Linguistics: ACL-IJCNLP 2021 · [licence](https://creativecommons.org/licenses/by/4.0/)

- [Publisher's page](https://aclanthology.org/2021.findings-acl.263/)
- [PDF](https://aclanthology.org/2021.findings-acl.263.pdf)
- [DOI 10.18653/v1/2021.findings-acl.263](https://doi.org/10.18653/v1/2021.findings-acl.263)

## Summary

Knowing that a poodle is a dog involves more than recognizing that the words tend to appear together. It means knowing which concept is broader and how the pair fits into a hierarchy that also includes animals. Carlos Aspillaga, Marcelo Mendoza and Alvaro Soto ask how much of this organization can be recovered from pretrained word representations. They use [WordNet](https://md.research.elamur.ai/free/en/papers/miller-1994-wordnet/), a lexical database that separates word senses and connects them through named relations, as their reference. The study concentrates on the relation between a category and its subtypes, including both immediate links and links that pass through intermediate categories.

The authors train a small classifier on pairs of concepts while keeping the pretrained representations fixed. For systems that represent a word in context, the classifier receives vectors taken from annotated WordNet glosses, where the intended sense of each mention is known. The test concepts are held out from classifier training and validation. All the systems supply useful evidence for the task, and representations from contextual encoders generally yield stronger results when information from all layers is used. RoBERTa-base reaches an F1-score of .8392 in that setting. The authors then try to assemble a hierarchy from the pair scores. On a selected set of 46 held-out concepts, BERT, ALBERT and XLNet give some of the closest reconstructions to the WordNet reference. The reconstructed hierarchies can recover broad categories while misplacing finer connections.

The errors vary with the concepts and with the source of the representations. Nearby concepts in the hierarchy are easier to connect than distant ones, and more specific concepts generally prove harder. The taxonomic group category is difficult across the systems studied. The layer comparisons also show that useful information becomes accessible at different depths. BERT and RoBERTa give strong results in their upper layers, whereas XLNet and ALBERT give stronger results earlier. Together, the experiments show that concept relations can be recovered from frozen representations with a trained classifier, while leaving open how much of that structure the original systems use in their own tasks.

## Deep dive: Inspecting the concept knowledge graph encoded by modern language models

A WordNet probe tests which concept hierarchies can be recovered from pretrained word representations and where that reconstruction breaks down. · about 37 minutes to read

**In this deep dive**

1. [The problem and its context](#dd-the-problem-and-its-context)
2. [The method, step by step](#dd-the-method-step-by-step)
3. [Experiments and results](#dd-experiments-and-results)
4. [What the ablations show](#dd-what-the-ablations-show)
5. [Limitations](#dd-limitations)
6. [What came after](#dd-what-came-after)

### The problem and its context

#### From task performance to an internal test

A system can perform a language task well while offering little direct evidence about how it arrived at its answer. The paper begins with this problem for pretrained systems used in [natural language processing](https://md.research.elamur.ai/free/en/concepts/natural-language-processing/). The usual procedure starts with representations learned from a large body of unlabeled text and then uses [fine-tuning](https://md.research.elamur.ai/free/en/concepts/fine-tuning/) to adapt the system to a particular task. The resulting task score reflects what the adapted system can do. The authors want to examine what a representation already makes available before that adaptation, with a target precise enough to compare different architectures and pretraining approaches.

Syntax gave earlier researchers a way to make that question concrete. The paper describes work relating particular BERT attention heads to syntactic phenomena and work testing sensitivity to subject–verb agreement. It also discusses a structural probe that recovered information about syntax trees through a linear transformation of BERT vectors. A syntax tree supplies observable relationships that a researcher can compare with properties of a representation. An experiment can therefore ask whether the geometry of the vectors supports those relationships under a specified readout, rather than inferring what must be inside the system from a benchmark score alone.

The evidence on meaning was more varied. The authors describe encouraging results for entity types, semantic roles and some sentence completion tests. They also describe weaker or less conclusive evidence from [coreference resolution](https://md.research.elamur.ai/free/en/concepts/coreference-resolution/), multiple-choice reading comprehension and lexical relation inference. In work on sentence structure, the improvements of contextual representations over a static baseline were reported to be clear for syntactic tests, with much weaker evidence of an advantage on semantic tests. Some research pointed to distinct regions or directions in BERT's geometry for linguistic information. Other research that examined self-attention found evidence of redundancy, leaving the implications for language understanding open.

These results concern different abilities. Identifying what kind of entity a phrase refers to, identifying what role a participant plays in an event, and determining which category a concept belongs to each put different demands on a representation. A test that succeeds on one of them can establish that particular result without settling the others. Aspillaga and colleagues narrow their question to [lexical semantics](https://md.research.elamur.ai/free/en/concepts/lexical-semantics/), specifically whether representations support the recovery of WordNet's hierarchy of concepts. This gives the study a reference that can be used both to label individual comparisons and to judge the structure obtained when those comparisons are put together.

Earlier work also gave conflicting indications about where semantic evidence might be found. The paper describes studies that associate lower layers with short syntactic dependencies and higher layers with longer ones, alongside studies suggesting that higher layers are also important for meaning. It points out that the evidence for the latter claim was uneven across tasks. Other work examined how representations change under task adaptation, how attention heads behave and what happens when heads are removed. These approaches motivate looking inside the system, but they ask different questions. The study here measures how useful the output of a layer is to a classifier trained to recognize a particular semantic relation. That makes layer location an experimental question instead of an assumption about where meaning ought to reside.

#### Why use a hierarchy of senses?

The authors choose a human-built [knowledge graph](https://md.research.elamur.ai/free/en/concepts/knowledge-graph/) as the reference. A WordNet node is a synset, a grouping of lexical items that express a particular sense. Several words can name the same concept, and the same written word can be associated with several concepts. The paper gives 117,000 as the number of WordNet synsets overall. A representation of a word in a sentence can therefore be evaluated against an intended sense, and a relation between senses can be assessed independently of which of their lexical forms appears in a given gloss.

The chosen relation is hypernymy. A hypernym is the broader concept, and a hyponym is the more specific one. Dog is a hypernym of poodle, and poodle is a hyponym of dog. The relation is directional, so recognizing a meaningful connection between the two items is only part of the task. The classifier has to put the concepts in the right roles. The relation also extends through the hierarchy. Animal can be a valid hypernym for poodle even when the graph reaches it through intermediate concepts. This gives the authors a way to test two related questions: can a probe identify valid ancestry, and can the resulting scores recover which concepts sit immediately above others?

An immediate link matters because it determines how a classification is organized. A set of true statements saying that several things are animals gives some information about their common category. It leaves more detailed questions about the placement of each concept unresolved. A test of pair labels alone could give the same credit to a broad, correct ancestry relation and to a correct relation with an immediate parent. Recovering a graph requires enough distinction among valid parents to choose a local attachment. That extra requirement makes graph reconstruction a separate experiment, even though both tasks use the same underlying classifier.

The paper situates the study alongside earlier methods for [information extraction](https://md.research.elamur.ai/free/en/concepts/information-extraction/). Work on extracting concept relations has used manually defined patterns, hand-designed features and measures of distance. Later approaches discussed in the paper used convolutional or recurrent networks and attention. The WordNet task here serves as an instrument for inspecting representations. Its classification accuracy is useful because the authors keep the rest of the measurement procedure similar while changing the source of the vectors. The paper's aim is to learn what those inputs contribute and where the same procedure consistently runs into trouble.

#### Why learn a probe?

Prompting offers another way to look for evidence of semantic knowledge. In a sentence completion test, a researcher writes text that makes a desired answer appropriate and inspects the predicted completion. The authors discuss this approach in connection with work such as [Language Models as Knowledge Bases?](https://md.research.elamur.ai/free/en/papers/petroni-2019-language-models-as-knowledge-bases/). They also note the sensitivity of such tests to how the prompt is written. Their study gives the question a different form. A supervised classifier reads vectors for concept mentions and learns to answer a specified relationship question. This lets the researchers pose the same question even when the underlying systems expose different ways of processing or producing text.

The authors also discuss resources that supply labeled examples for semantic evaluation. They point to BLESS as an example with gold annotations for 200 concepts, illustrating the limited coverage of some existing resources relative to WordNet. The gloss corpus used in their study brings together a different combination of ingredients. It supplies contexts for sense-specific mentions, and WordNet supplies relationships among the concepts those mentions refer to. The sense labels make it possible to ask about the hierarchy even when two occurrences have different lexical forms. They also let the researchers organize their train and test splits around concepts.

A probe is itself a learned classifier. Its performance depends both on what the input vectors make available and on what the classifier can learn from supervised examples. The authors address this by holding the source systems fixed, applying a common type of classifier and training another probe on frozen random vectors. They also split the examples so that the test concerns new concepts. The strongest reading of a positive result is thus specific: under this data construction and readout, the fixed representations help the classifier generalize a WordNet relation to concepts that it did not encounter during training.

### The method, step by step

#### Turn definitions into examples of concept mentions

The starting point is the Princeton WordNet Gloss Corpus. A gloss is a short description of a sense. In this corpus, annotations identify occurrences of words in gloss sentences and match them to their intended WordNet synsets. The researchers can retrieve a context in which a concept appears and use the annotation to select the relevant mention. This is important whenever a spelling can express several senses. The classifier's target comes from the synset assigned to the particular occurrence, so the supervision concerns a sense in context even though some of the source representations can only supply a general vector for the word.

The selected annotations cover 41,502 lemmas and correspond to 34,371 WordNet synsets. A [lemma](https://md.research.elamur.ai/free/en/concepts/lemma/) is the lexical form used to identify a word. Here, forms such as home and residence can be associated with the same synset in the appropriate sense. The authors report 230215 valid WordNet relations from the selected material. These counts describe different parts of the resource. The lemma count describes the lexical forms, the synset count describes the concepts, and the relation count describes available connections. A classifier example combines a pairing of synsets with lexical material through which it can obtain their representations.

The authors allocated 70% of the synsets to training, 15% to validation, and 15% to testing. They describe keeping concepts and their associated lemmas within their assigned partitions. In their house example, assigning the relevant concept to training also puts its associated lexical alternatives in training. This makes a split by concept more demanding than holding out new sentences that mention the same concepts. It tests whether the probe can use what it learned about the relation without having already fitted a label to the particular concept that appears in the test example.

The partitions maintain the same proportion of leaf nodes and internal nodes. A leaf sits at the end of a branch and has no descendant in the hierarchy under consideration. Internal nodes have descendants, so their presence matters when the researchers sample ancestors and subtypes. The authors also try, where possible, to balance how frequently a concept appears in the broader and narrower roles. This addresses a shortcut discussed in prior work. If some words occur overwhelmingly as hypernyms, a classifier may do well by detecting that a word is a typical category name. Exposure to both roles gives it more reason to use evidence about the current pair.

#### Make an ordered classification task

The authors build examples around a triplet of synsets. First they choose a synset and one of its direct or indirect hypernyms. When several hypernyms are available, the choice among them is random. They then draw another synset from an unrelated part of WordNet, checking that it has no relevant hierarchical relation to either member of the initial pair. The third concept supplies negative examples with different pair members. Reversing the original pair supplies a negative example that contains the same concepts as the positive one.

```
x, y ∈ {A, B, C}, x ≠ y
```

Here, A is the starting synset, B is its sampled hypernym and C is the unrelated synset. The letters x and y identify the first and second positions of an example pair. The membership symbol ∈ limits those positions to the three sampled concepts. The braces enclose that set, and ≠ excludes a pairing of a concept with itself.

The six eligible orderings produce one positive and five negative examples in the construction described by the authors. The pair with A first and B second is positive because B is an ancestor of A. With B first and A second, the question becomes whether A is an ancestor of B, so the pair is negative. That example is particularly informative about what the test demands. Both orders contain the same senses, and a measure of undirected similarity would assign them the same value. The probe has to make use of the ordering. The other negative examples pair the unrelated concept with one of the original concepts in either orientation.

```
L = 1 if y is a direct or indirect parent of x
    0 otherwise
```

L is the target label. The equals sign assigns the value 1 to a positive pair and 0 to a negative one. Here x denotes the proposed subtype and y the proposed ancestor. A direct parent is connected to x without an intermediate category, while an indirect parent is reachable farther up the hierarchy. Both give the positive label. The graph reconstruction later uses parent-first notation for its directed edges, so the same valid relation is written with the two concepts in the opposite order there.

During training, the authors sample hypernyms and unrelated concepts so that every training synset appears at least once. Their triplet construction gives the negative class more examples, and the loss compensates for this by weighting a positive example by 5 and a negative example by 1. The loss is weighted binary cross-entropy, which penalizes the classifier for assigning low probability to the true label. The weights give the two classes equal aggregate influence under the triplet construction. That is a property of how the training loss treats the sampled examples. It does not imply the same mix of valid and invalid links when every ordered pair from a set of concepts is examined.

#### Read the frozen representations

The comparison uses several versions of nine systems from three families. Word2Vec and [GloVe](https://md.research.elamur.ai/free/en/concepts/glove/) supply static [word embeddings](https://md.research.elamur.ai/free/en/concepts/word-embeddings/). A static embedding represents the lexical item with a fixed vector regardless of the sentence in which it appears. The contextual encoders include ELMo, [BERT](https://md.research.elamur.ai/free/en/papers/devlin-2019-bert-pre-training-deep-bidirectional/) and [RoBERTa](https://md.research.elamur.ai/free/en/papers/liu-2019-roberta-robustly-optimized-bert-pretraining/). The same group also includes [XLNet](https://md.research.elamur.ai/free/en/papers/yang-2019-xlnet-generalized-autoregressive-pretraining-language/) and [ALBERT](https://md.research.elamur.ai/free/en/papers/lan-2019-albert-lite-bert-self-supervised/). ELMo uses a bidirectional recurrent architecture. The others in that group use the [Transformer](https://md.research.elamur.ai/free/en/concepts/transformer/). GPT-2 and [T5](https://md.research.elamur.ai/free/en/papers/raffel-2019-exploring-limits-transfer-learning-unified/) represent the generative family in the paper's grouping.

A concept must be represented through some lexical occurrence to enter the classifier. The authors sample a gloss sentence for each concept in a pair. For a static system, they use the embedding of the relevant lexical item. For a contextual encoder or a generative system, they first process the gloss sentence so that the representation of the selected mention can reflect the surrounding text. The classifier receives the hidden states for the first token of the specific mention. In the main all-layer condition, those states are concatenated, which means laying the layer vectors end to end to form a single input vector. In the layer comparison, the vector comes from just the layer being tested.

```
M(x), M(y)
```

M denotes the frozen source of embeddings, and x and y are the two synsets in the pair. Parentheses indicate applying M to obtain a representation. For the static systems, M(x) and M(y) stand for the embeddings of the lexical forms used for the respective synsets.

```
M(S(x)), M(S(y))
```

S maps each of the synsets x and y to its sampled gloss sentence. M applied to S(x) or S(y) yields the sentence's representations. From each result, the procedure retains the states at the selected token corresponding to the annotated mention. The nested parentheses show the order of operations: select the context, process it, and then read out the mention's representation. The gloss therefore affects the contextual vector through the source system. The probe itself operates on the resulting vectors.

The paper's implementation description also specifies that when a gloss has multiple tagged tokens, the analysis takes the first. The representation is consequently built around a selected occurrence and token position, not a pooled description of every concept mentioned in the gloss. This choice gives the probe consistent inputs that can be extracted from every layer. It also defines what the layer results are about. They measure access to the relation from the chosen token state, under the paper's gloss-based representation procedure.

#### Train a shared kind of classifier

The input vectors vary substantially in width across architectures and across layer conditions. The probe applies a linear layer to project each concept's input into a common space of lower dimensionality. The two projected vectors, which the paper denotes by x′ and y′, are concatenated in pair order. The primes distinguish the projected representations from their original inputs. A multilayer perceptron then reads the joined vector and predicts the label. This is a feedforward classifier whose hidden layer allows the evidence for the label to depend on a nonlinear combination of the two representations.

The classifier has one hidden layer of 384 units. The training setup uses dropout at 0.425 and L2 regularization. Dropout reduces reliance on any fixed set of activations during training, and L2 regularization penalizes large weights. The parameters that may change are in the linear projection and the classifier. The source of the embeddings stays frozen throughout. That separation is central to the experiment. Supervised exposure to WordNet can teach the readout how to use the vectors, while any advantage of one source over another has to come through vectors it already produces under the chosen input procedure.

From annotated WordNet glosses to reconstructed concept hierarchies The steps in order.

#### Use ancestry scores to identify direct parents

A positive ancestry prediction can describe a direct link or a path with intermediate concepts. To reconstruct a hierarchy, the authors need to decide which positive links are plausible as direct attachments. They score candidate edges in parent-first order and introduce a cost that estimates how close the proposed parent is to its child. An especially useful candidate has both a convincing direction and a small estimated distance. The paper considers two ways of obtaining that distance from the same classifier outputs.

```
h⟨u,v⟩ ∈ [0, 1]
```

Here u is the proposed parent, v is the proposed child and ⟨u,v⟩ denotes their ordered pair. The symbol h⟨u,v⟩ is the classifier's score for u being an ancestor of v, using this parent-first convention. The symbol ∈ indicates that the score lies between 0 and 1, and the brackets include both endpoints. In the reconstruction description, a score above a threshold indicates a valid candidate ancestry relation. The appendix presents the spanning problem using a dense auxiliary graph of candidate edges.

The Model Confidence Metric, or MCM, uses the classifier's score directly. Its motivation comes from the observation that nearby relations tend to be easier for the probe than those spanning more of the hierarchy. Dog should then receive a stronger score as a parent of poodle than a more remote ancestor does. Converting the score to a cost lets the tree procedure favor stronger connections through its minimization objective.

```
dₑ(u, v) = 1 − h⟨u,v⟩
```

The symbol e denotes the edge ⟨u,v⟩, with proposed parent u and proposed child v. The quantity dₑ(u, v) is its estimated parent distance. The subtraction sign means that the classifier score h⟨u,v⟩ is taken away from 1. Larger confidence therefore corresponds to smaller cost. The cost is based on the output for the specified pair alone, so a mistake in that output can directly affect which parent the algorithm prefers.

The Transitive Intersections Metric, or TIM, uses the relations predicted for other nodes as additional evidence. If u is a parent of v, descendants of v should also be descendants of u. Similarly, ancestors of u should also be ancestors of v. The authors expect closer links to be associated with greater overlap. Rather than reducing each of those relationships to a yes-or-no decision before measuring the overlap, the formula multiplies the corresponding scores. It then combines the evidence from the shared descendants and shared ancestors.

```
dₑ(u, v) = −(Σ[j ∈ N ∖ {u,v}] (h⟨u,j⟩ h⟨v,j⟩ + h⟨j,u⟩ h⟨j,v⟩)) × h⟨u,v⟩
```

Again, dₑ(u, v) is the cost of the proposed edge e from parent u to child v. N is the set of concepts in the reconstruction, and j indexes the other concepts. The summation sign Σ collects their contributions. The membership symbol ∈ and the set difference sign ∖ restrict j to members of N outside the set {u,v}. Each h is an ordered ancestry score. The adjacent terms h⟨u,j⟩ and h⟨v,j⟩ are multiplied to express evidence that j is a descendant of both endpoints. The product h⟨j,u⟩ h⟨j,v⟩ expresses evidence that j is an ancestor of both. The plus sign combines the two types of overlap. The leading minus sign makes greater overlap correspond to lower cost, and × h⟨u,v⟩ scales that evidence by the confidence in the proposed direction.

TIM can use consistent evidence from several other concepts to favor an attachment. Its evidence depends on which concepts happen to be included in the reconstruction and on the predictions made for them. For example, a well-supported group of descendants can strengthen a link between two candidate parents of that group. If the relevant descendants are absent, the method has fewer opportunities to use that type of evidence. The two costs thus ask different questions of the same classifier: how convincing is this individual ordered pair, and how well does it fit the predicted ancestral and descendant relationships in the selected graph?

#### Choose a directed tree

The nodes of the target graph G are known, and its edge set E is what the authors want to estimate. They define an auxiliary graph G′ on the same set N, with candidate directed edges E′. Each candidate has an ancestry score hₑ and an estimated parent distance dₑ. A binary selection variable xₑ records whether an edge enters the reconstruction. The selected structure is an arborescence, a directed tree oriented outward from a root. Every other node receives a parent, and there must be a directed path from the root to each node. These conditions make the edges a connected hierarchy.

```
δ(v) = {⟨u,v⟩ : u ∈ N, u ≠ v}
```

The symbol δ(v) denotes the set of candidate edges entering node v. Each ordered pair ⟨u,v⟩ has proposed parent u and proposed child v. The colon introduces the conditions for membership in the set. The condition u ∈ N says that u is a node of the graph, and u ≠ v excludes self-links.

```
γ(S) = {⟨u,v⟩ ∈ E′ : u ∉ S, v ∈ S}
```

The symbol γ(S) denotes the candidate edges entering the subset S from outside it. Here E′ is the auxiliary edge set. The condition u ∉ S places the candidate parent outside the subset, and v ∈ S places the candidate child within it. The colon separates the candidate edges from the conditions selecting the relevant ones.

```
xₑ ∈ {0, 1}    for each e ∈ E′
```

The variable xₑ is the indicator for edge e. The braces give its admissible values, membership in E′ means that e is a candidate edge, and ∈ {0, 1} restricts the indicator to selection, represented by 1, or omission, represented by 0.

```
Σ[e ∈ δ(v)] xₑ = 1    for every v ∈ N ∖ {r}
```

Here r is the proposed root, and N ∖ {r} is the set of all nodes other than that root. For each such v, the summation Σ runs over the incoming candidates e in δ(v). The equality to 1 requires exactly one selected incoming edge for v, giving each nonroot node a parent.

```
Σ[e ∈ γ(S)] xₑ ≥ 1    for subsets S ⊂ N ∖ {r}
```

Here S is a subset of nodes away from the root, denoted by ⊂. The sum counts selected edges entering that subset through γ(S). The inequality ≥ 1 requires an entering edge for each such nonempty set. This is the connectivity condition. A collection of nodes with links only among themselves would have no selected edge entering the collection from outside, so it could not form a detached component of the solution.

```
X* = arg minₓ Σ[e ∈ E′] xₑ dₑ
```

For a candidate root r, X* denotes the minimizing edge selections under the binary, incoming-edge and connectivity constraints. The asterisk marks optimality. The expression arg minₓ asks for the assignment x of the edge indicators that makes the sum smallest. The summation ranges over the candidate edge set E′. Each term xₑ dₑ contributes the estimated distance dₑ when edge e is selected. This is the minimum-spanning-arborescence step. It selects a coherent directed tree using the costs from MCM or TIM.

```
maximize over r ∈ N: Σ[e ∈ E′] xₑ hₑ, subject to x ∈ X*
```

Here r ranges over the nodes N as a possible root. The assignment x must belong to the set X* of minimum-cost selections for that root. The score hₑ is the probe's estimate for the direction of edge e, so the sum adds the confidence of the selected edges. The outer objective uses that total to choose the root, while the inner objective uses parent-distance costs to obtain the rooted reconstruction. The selected edges estimate E, the links of the unknown hierarchy.

#### Measure distance in the reference hierarchy

The study also needs a distance taken from WordNet itself, for an analysis of which pairs are easy or hard. This distance is separate from the estimated edge costs. It is measured in hops, with each hop representing the traversal of a link in the reference graph. For a pair in the positive orientation, the authors use the shortest route to the ancestor. In the other case, they use the routes from each concept to the closest common ancestor.

```
d_W(x, y) = d_path(x, y)                  if y is an ancestor of x
            d_path(x, z) + d_path(y, z)   otherwise
```

The quantity d_W(x, y) is the WordNet distance for synsets x and y. The subscript W identifies WordNet. The function d_path denotes the length of a shortest path in hops between its arguments. In the first case, the path connects x to its ancestor y. In the second case, z denotes the closest common ancestor, and the plus sign combines the lengths from x and y to z. This measure supplies the reference separation for grouping test pairs. The authors can then check whether a probe that performs well on close pairs has comparable success as the separation increases.

### Experiments and results

#### How well does the probe classify held-out pairs?

The pair experiment uses F1-score to assess the identification of valid ancestry relations. Precision concerns how frequently the pairs predicted to have the relation actually have it. Recall concerns how often the valid relations are found. F1 combines these aspects of performance. A classifier that predicts the positive relation very freely can find many valid pairs while including many false links. A more selective classifier can miss true links. The metric gives the researchers a way to compare sources under the same labeled-pair procedure while accounting for both types of error.

Each trained probe receives its input from one of the fixed sources. Word2Vec and GloVe-42B provide static baselines. The contextual and generative representations are evaluated both as combinations of layers and as individual layer inputs. There is also a control using random vectors matched in size to the real ones and kept frozen for training and inference. The random-vector control reaches around 50% accuracy in the binary task, which the authors interpret as performance around chance in that control. Accuracy is the metric they give for this check. The comparisons among pretrained representations below use F1-score.

The static baselines establish that useful hierarchy information is available even when the representation of a word stays the same across its contexts. On the held-out pair task, Word2Vec records .7683 ± .0135 F1 and GloVe-42B records .7877 ± .0084 F1. Among the generative systems, GPT-2 records .7862 ± .0132 using all layers, while T5-small records .8156 ± .0098 in that condition. The strongest all-layer results generally come from the contextual encoders. For example, BERT-base reaches .8240 ± .0123, XLNet-base reaches .8306 ± .0113, and RoBERTa-base reaches .8392 ± .0100. The spread across families coexists with close results for individual systems from different families.

Selected systems on WordNet held-out edge prediction, all-layer F1 The strongest contextual encoders lead the selected static and generative baselines.

**The numbers**

| System or setting | F1 |
| --- | --- |
| Word2Vec | .7683 |
| GloVe-42B | .7877 |
| GPT-2 | .7862 |
| T5-small | .8156 |
| ELMo-large | .8311 |
| BERT-base | .8240 |
| XLNet-base | .8306 |
| RoBERTa-base (this paper) | .8392 |

The static rows use the systems' fixed vectors, so the all-layer designation applies to the systems that have layer states to combine. The F1 results show that contextual encoders usually make this WordNet relation easier to recover with the probe, while the ordering depends on the comparison setting. ELMo-small, for example, scores .7986 ± .0126 with all layers and ELMo-large scores .8311 ± .0090. RoBERTa-base scores .8392 ± .0100, and RoBERTa-large scores .8219 ± .0159. An increase in size therefore accompanies improved all-layer performance in the ELMo comparison and reduced all-layer performance in the RoBERTa comparison.

The best individual layer can change the ordering again. T5-large gives .8148 ± .0119 using all layers and .8331 ± .0102 for its best layer, layer 17. ELMo-large reaches .8330 ± .0083 for its best layer, layer 2. GPT2-xl rises from .7946 ± .0151 with all layers to .8029 ± .0118 for its best layer, layer 13. These results are still measurements on the held-out pair task. They show how the choice of what to feed the classifier can affect comparisons, even though the source weights and the target relation stay fixed.

Comparing one source across layer settings also clarifies what an all-layer advantage means. BERT-base records .8240 ± .0123 with the concatenated representation and .8185 ± .0104 for its best layer, layer 10. The best layer of XLNet-base is layer 4, with .8293 ± .0116 against an all-layer score of .8306 ± .0113. Thus a single layer can give close to the concatenated result even when the location of that layer differs between architectures. The paper uses these measurements to lead into the layer-by-layer profiles, where the shape of the performance curve matters alongside its maximum.

#### Can the pair scores reconstruct a hierarchy?

For reconstruction, the authors choose 46 nodes that were absent from training and validation. They select concepts with recognizable relationships so the resulting diagrams can be inspected. The smaller graph also keeps the number of candidate comparisons manageable. The paper places the cost of examining all candidate concept pairs at at least quadratic growth in the number of concepts and reports that WordNet has over 82,000 noun synsets. It therefore treats the reconstruction as a test on a selected subgraph. Within that test, the procedure compares potential parents among the given nodes and assembles the resulting edges into a tree.

The metric is tree edit distance, which measures the amount of editing needed to bring a predicted tree into agreement with the reference. Smaller distance indicates closer agreement. The paper reports the reconstruction comparison for the larger system variants, applying both parent-distance estimates and comparing their results with the WordNet reference tree. It identifies the contextual encoders as generally producing trees closer to the reference than the static or generative representations. BERT, ALBERT and XLNet are singled out for the strongest reconstruction results. The pair results and the tree results agree in their broad advantage for contextual encoders, while highlighting different systems within that group.

The BERT-large reconstruction illustrates what partial success looks like. Recognizable categories emerge, but inspection reveals errors in the placement of finer relationships. At the pair level, a classifier can identify several valid ancestors of the same concept. At the tree level, it has to provide scores that help the algorithm favor the most suitable immediate parent and do so consistently across the graph. A mistaken attachment can alter all the ancestor relationships implied by the path through that attachment. Tree edit distance and pairwise F1 therefore report different consequences of the same underlying scores.

Reconstruction also places more weight on how the classifier treats irrelevant pairs. The sampled pair test gives the researchers deliberate positive and negative cases, including reversed ancestors and a randomly selected unrelated concept. In a graph of many concepts, a node can have many candidate parents that should be rejected. Even a classifier whose aggregate pair score is strong can give an incorrect candidate enough confidence to affect the tree. The authors read the two experiments together for this reason. The pair test establishes the quality of individually sampled decisions, and the graph test exposes the effect of using those decisions to impose a coherent structure.

### What the ablations show

#### What changes when the readout or its inputs change?

The study combines controlled changes to the probe inputs with analyses that group examples by semantic properties. The random-vector control asks whether the classifier and the available supervision can produce the reported performance without informative pretrained inputs. It retains the vector width of the real input and freezes the alternative vectors. The result of around 50% accuracy supports the view that the advantage of the real representations depends on their content. In combination with the held-out concepts, the control weakens an explanation based solely on the probe memorizing concept identities from training examples.

The authors also report trying readouts based on linear transformations, following the general inspiration of earlier work on syntax trees. Those attempts did not recover WordNet's structure. The paper interprets this outcome as evidence that the semantic relationships are not readily available through the kind of linear geometry tested. Its chosen probe includes a nonlinear hidden layer so it can combine the two concept vectors in more flexible ways. The outcome of the linear attempt is evidence about the tested readout. The reported comparison leaves open how a different linear probe, an alternative representation of a concept, or another target derived from WordNet might perform.

The layer experiment changes which hidden state reaches the classifier. For a single-layer condition, the probe receives that layer's representation of the selected token. The all-layer condition supplies the concatenation. Every generative variant in the pair results has a higher best-layer F1 than its corresponding all-layer F1. For GPT-2, the comparison is .7921 ± .0108 at its strongest individual layer and .7862 ± .0132 using all layers. For T5-small it is .8199 ± .0081 at its strongest layer and .8156 ± .0098 using all layers. The authors suggest that some upper layers may be tuned toward producing text, making ancestry less accessible through the probe.

The contextual encoders more often keep or improve performance when layers are combined, though some variants achieve their strongest results with an individual layer. RoBERTa-large, for instance, records .8314 ± .0082 at its best individual layer and .8219 ± .0159 with all layers. RoBERTa-base shows the reverse ordering for its own two conditions. The comparison changes the input width as well as the amount and source of layer information. It measures which input configuration works better with this trained readout. A larger vector may contain more potential evidence while also making the relevant evidence harder for the probe to isolate.

#### Where is the relation easiest to read out?

The full layer profiles show different patterns even among the contextual encoders. BERT and RoBERTa have strong upper layers, while XLNet and ALBERT tend to provide their strongest pair evidence earlier. For BERT-large, the table identifies layer 14 as giving the best single-layer result, with .8185 ± .0113 F1. For XLNet-large, it identifies layer 6, with .8244 ± .0080. ALBERT-xxlarge gives its best result at layer 4, with .8194 ± .0097. The paper observes similar patterns of rise and fall for smaller and larger variants of the same architecture. The location of a strong readout appears more stable across those variants than across different architectures.

GPT-2 and T5 offer a further comparison. The authors describe the GPT-2 profile as showing semantic evidence across its layers, even though the best individual layer can give a slightly stronger result than the concatenated input. For T5, the curve has an M shape associated with its encoder–decoder organization. The authors identify the encoder as the main source of the evidence for this task. A high score for a particular layer means that a supervised probe can recover the relation from that layer's outputs. It does not by itself reveal the processing steps by which the representation acquired the information or the later operations that use it.

The paper connects these profiles to experiments on adaptation and early exiting, in which a system makes its prediction before using every layer. Its proposal is that an architecture whose useful signals emerge earlier may offer different opportunities for selective use of layers than one with a stronger signal high in the stack. It also suggests that layer-specific learning rates could help preserve useful information during adaptation. Those are implications the authors draw from the layer profiles. The profiles themselves measure WordNet edge classification, so the effect of changing which layers a downstream task uses would require evaluation on that task.

#### Which concepts and relations cause errors?

The semantic analysis separates several properties that might make a relation easy or hard. The plots display ranges with at least 100 samples and show 90% confidence intervals. One property is relative depth, with 0 % denoting the root and 100 % denoting leaves. Most systems do worse as concepts become more specific. The number of subclasses gives a related perspective: F1 tends to be higher for concepts with more subclasses. The authors hypothesize that broad categories are encountered in more varied settings, including settings involving their subtypes, whereas narrowly defined concepts have fewer and more specialized contexts from which to learn.

Graph distance concerns the separation between the concepts in the pair, rather than the depth of one of them. The paper's comparison of a chihuahua with a dog and a chihuahua with an entity illustrates the distinction. The subtype is the same, but the proposed ancestors are a different number of hops away. The analysis finds that short-distance relations are generally easier across the systems studied. That observation motivates the confidence-based distance in the reconstruction procedure. It supports using strong confidence as a clue to closeness, while leaving room for uncertainty about the relative ordering of particular candidate parents.

Frequency adds another dimension. The authors estimate it by counting occurrences in the 38 GB OpenWebText corpus. They report that F1 declines for very frequent concepts, with greater sensitivity in the static and generative families. The corpus supplies a common frequency measure for the analysis rather than direct counts from each system's own pretraining data. The measured relationship therefore concerns frequency as estimated on that reference corpus. Combined with the depth and subclass results, it shows why a simple account based on seeing a term more frequently is insufficient. Breadth in the hierarchy and frequency of occurrence give different views of the examples on which the classifier succeeds.

The authors also group results by the number of senses associated with a word, the frequency rank of the relevant sense and the number of sibling concepts. The contextual and generative representations show fairly flat patterns across those factors, especially for the contextual encoders. In the authors’ view, these results suggest that context from the annotated gloss helps the representations identify the intended sense even if the lexical form has multiple meanings. Static embeddings cannot adapt their vector to each gloss. The paper connects their greater sensitivity to prior work showing that a fixed word vector tends to represent its frequent senses more clearly.

These patterns concern associations within the sample. A small change across bins for sense count can coexist with sharp errors for particular ambiguous terms or in particular categories. The gloss corpus also supplies contexts associated with lexical definitions, which may give distinctive clues to the intended sense. The analysis shows that the relation can be recovered with relatively stable F1 across the measured sense conditions in this setup. It does not isolate the contribution of the target word from that of its context. The authors' account of how context might help is therefore an explanation of the observed pattern, while the plots supply the pattern itself.

#### Where do the family-level rankings reverse?

The category comparisons show why a strong overall F1 can conceal a weakness on particular branches. The paper reports mean F1 over the concepts in each analyzed category. On social group, BERT reaches .8516, ALBERT .8556 and GPT-2 .8155. On taxonomic group, the same systems score .4804, .4277 and .3030. The static Word2Vec baseline scores .7497 on social group and .6920 on taxonomic group. It gives up ground to the contextual encoders on the former and leads them on the latter. T5 records .6944 for taxonomic group, the highest mean in the paper's comparison of that category.

Systems on the WordNet taxonomic group category, mean edge-probe F1 T5 and the static embeddings lead a category that is difficult across families.

**The numbers**

| System or setting | F1 |
| --- | --- |
| Word2Vec | .6920 |
| GloVe-42B | .6648 |
| GPT-2 | .3030 |
| T5 (this paper) | .6944 |
| ELMo | .6011 |
| BERT | .4804 |
| RoBERTa | .4921 |
| XLNet | .5371 |
| ALBERT | .4277 |

The category averages also hide variation within a branch. The appendix reports BERT's mean and standard deviation as .5626 ± .1537 for family and .3696 ± .1857 for genus. For T5 the corresponding category scores are .6691 ± .1276 and .7156 ± .1001. The direction of the difference between these categories varies by system. Elsewhere, ELMo reaches .8187 for living thing, compared with BERT's .7593, while the artifact category gives .8308 for ELMo and .8249 for BERT. These figures describe category means, so they are evidence about the tested concepts in those categories rather than expectations for each individual concept.

From manual inspection, the authors suggest that some taxonomic gloss contexts give weak cues to the exact concept. A different concept can fit in the same place and yield a modified sentence that still makes sense. A contextual representation may capture features shared by those plausible replacements without sharply distinguishing their particular taxonomic positions. The authors contrast this with their inspection of categories such as social group and attribute. The explanation comes from reading examples. The reported experiment does not replace words in a controlled fashion and measure how the vectors or scores change as a result.

#### What do size and corpus comparisons tell us?

The authors compare their layer results with descriptions of the corpora used in pretraining. They list, for instance, BERT at 3.9B tokens and 16GB, RoBERTa at 160GB, and T5 at 750GB. Some token counts and corpus sizes in the paper are estimates based on available descriptions. Larger corpora occur alongside different architectures, training objectives and representations. The authors observe that a larger corpus does not consistently accompany a higher score and suggest that increasing system size may offer more benefit on semantic tasks than simply adding text.

The results for individual variants make the scope of that interpretation important. ELMo-large improves over ELMo-small in both the all-layer and best-layer comparisons. T5-large improves over T5-small in the best-layer comparison, whereas T5-small has the higher all-layer result. The strongest comparison can therefore depend on how the vectors are read. The cross-system corpus table and the variant comparisons point to plausible influences on probe performance. They do not form a controlled experiment that varies corpus size while holding architecture, training and all other properties fixed. The paper's claim about corpus size is best read in the setting of the systems it compares.

### Limitations

#### Limits the authors state

The authors emphasize the difference between sampled edge classification and whole-graph reconstruction. A single mistaken parent can produce a different ancestry path for several descendants. The probe's F1 on local examples consequently cannot stand in for the quality of the structure obtained after the scores are combined. The authors also point out that reconstruction can present a much larger proportion of negative candidate edges than the pair setup. Weighting examples during training gives the classes comparable influence for learning. Searching through many possible parents presents a different problem, because incorrect but high-scoring candidates compete directly for inclusion in the tree.

The graph experiment is limited in scope by the cost of candidate comparisons. The authors choose 46 held-out nodes partly to keep the computation manageable and the diagrams interpretable. The resulting trees show what the method can obtain from those concepts. A reconstruction across the noun hierarchy would involve a larger candidate set and many concepts beyond the chosen examples. The authors' observation that broad categories are easier to recover than finer links is consistent with the diagrams and pair analysis. The selection procedure leaves the quality of a more extensive reconstruction open.

For the category breakdown, the authors describe the analyzed categories as an incomplete and somewhat uneven set. The appendix says the selection was based on the number of subcategories. The mean F1 for taxonomic group, social group or any other label therefore reflects the concepts counted under that category in the experiment. Wide variation within some categories further limits what a mean can say about an individual concept. The semantic-factor plots have a related scope restriction, since they report ranges with enough sampled cases. An empty or omitted region of a plot supplies little evidence about how the system would behave there.

The paper also distinguishes recovering information with a classifier from showing that the source system relies on it. The authors suggest that semantic evidence may emerge indirectly from learning to process language, and they discuss earlier work questioning whether probe success implies relevance to a system's tasks. Their own measurements show how well a supervised readout can exploit the representations for WordNet ancestry. Determining whether a particular prediction depends on that information would require a test directed at the source system's behavior.

#### Limits of the setup

The probe's own training remains part of the explanation for every positive result. It sees labels and learns a nonlinear rule for mapping pairs of representations to those labels. Holding the source weights fixed shows that useful input differences already exist before this training. Holding out concepts shows that the learned rule can generalize under the paper's sampling scheme. Together these controls support recoverability. They leave open how much of the resulting decision rule is specific to the annotated WordNet examples, how directly the underlying vectors organize the relation, and whether a simpler readout with a different design could recover overlapping information.

The gloss context gives the contextual systems evidence that the static baseline cannot use. This is appropriate for comparing the representations that the systems naturally supply, but it gives the family comparison a precise interpretation. The stronger F1 of a contextual encoder can reflect successful use of information in a definition-style sentence as well as knowledge associated with the target lexical item. A gloss might describe properties that help identify the category or distinguish a sense. The study does not separately measure what would be recoverable from an isolated lexical item, from a wider variety of ordinary contexts, or after obscuring potentially informative words in the gloss.

The triplet construction controls some shortcuts and leaves others possible. The reversed positive pair tests direction with identical concept membership. Sampling C from a different part of the taxonomy gives useful negative pairs, but a collection dominated by distant alternatives places a different demand on the classifier from a collection of neighboring concepts with plausible but incorrect parent assignments. The authors' role-balancing procedure reduces reliance on typical hypernym words where it can. The classification experiment still evaluates decisions on the particular pairs it samples. The gap between its pair and tree results is one indication of why the composition of the negatives matters.

The graph procedure has structural assumptions of its own. It requires a rooted tree with a single selected parent for each nonroot node. The sampling procedure recognizes that WordNet can supply several hypernyms for a concept. A tree gives a tractable, interpretable arrangement for the selected nodes, but it cannot express multiple parent attachments at once. This affects the meaning of the reconstructed graph. It is an estimate under imposed structural constraints, built from selected concepts and relation scores. Its agreement with the reference measures success at that reconstruction task, and its whole topology cannot be attributed to the source vectors alone.

The layer experiments also leave causal questions unresolved. Reading from a lower layer and finding a good F1-score shows that the relation is accessible there under the tested classifier. A weaker score higher up might reflect a change in how the evidence is represented, an effect of the readout, or an actual reduction in the available signal. The experiment does not distinguish these possibilities by intervening in the computation. The paper's ideas about early exiting and layer-sensitive adaptation follow from where the probe succeeds, while their value for another task depends on that task's requirements and how the system produces its answers.

Finally, the findings concern a hierarchy of lexical concepts and its ancestry relation. Related areas of [knowledge representation and reasoning](https://md.research.elamur.ai/free/en/concepts/knowledge-representation/) pose different problems. Asking whether a system can recover an ancestor from gloss-based vectors leaves open whether it can independently state that relation, use it to draw a conclusion, or generalize to a different kind of relationship. The paper's data support the conclusion that useful information about WordNet's organization is recoverable, with systematic errors. They leave broader claims about semantic understanding open.

### What came after

Subsequent papers cite the study in connection with questions about factual generation, knowledge storage, predictive augmentation and the interpretation of probes. The documented connections establish that those works cite Aspillaga and colleagues. They leave the role of the WordNet experiment in each work's method or argument unspecified, so the relationships below are comparisons of research questions.

[Factuality Enhanced Language Models for Open-Ended Text Generation](https://md.research.elamur.ai/free/en/papers/lee-2022-factuality-enhanced-language-models-open/) takes factuality in open-ended generation as its subject. Aspillaga and colleagues measure the evidence for a specific relation in frozen vectors through a trained readout. A study of factual generation addresses the claims a system produces in its own text. That difference in what is evaluated matters. Evidence that a classifier can extract a concept relation from a representation and evidence that generated text reliably makes factual claims address distinct stages of language processing. The citation alone leaves open how the factuality study uses the earlier results.

[Physics of Language Models: Part 3.1, Knowledge Storage and Extraction](https://md.research.elamur.ai/free/en/papers/allen-zhu-2023-physics-language-models-part-3/) shares an explicit interest in the relation between knowledge storage and extraction. The WordNet study makes that distinction concrete by freezing the representation and specifying an extraction procedure with its own training data. Its outcome depends on both what is available in the representation and what the chosen probe can recover. The later title establishes a shared question about access to stored knowledge. It leaves open whether the work adopted the earlier classifier, used the same kinds of relations or cited the study to place a different experiment in context.

The paper on [augmenting BERT-style systems](https://md.research.elamur.ai/free/en/papers/araujo-2021-augmenting-bert-style-models-predictive/) is another citing work. The connection that can be made with confidence is its focus on BERT-style systems, whose concept representations are part of the earlier comparison. An augmentation study asks about changing a system or the evidence it receives, whereas the WordNet probe asks what a fixed representation makes available. The citation record supplies no basis for identifying an augmentation with either of the paper's parent-distance metrics or attributing a particular result to use of its findings.

[Compositional Meaning Representations in LLMs](https://md.research.elamur.ai/free/en/papers/marro-2026-compositional-meaning-representations-llms-critical/) is a critical review of probing studies. Aspillaga and colleagues provide an example of a probe trained on top of frozen representations, a concept-level evaluation split and a separate test of graph reconstruction. Those design choices make the paper pertinent to an examination of what probing can establish. The compositional question has a different target from lexical ancestry. The citation establishes a connection to the probing literature, while the review's specific assessment of the WordNet probe remains unspecified.

## Cite

Cite as Carlos Aspillaga, Marcelo Mendoza and Alvaro Soto. 2021. Inspecting the concept knowledge graph encoded by modern language models. Findings of the Association for Computational Linguistics: ACL-IJCNLP 2021.

The paper itself, not this page. BibTeX from the library's record of the work. [DOI 10.18653/v1/2021.findings-acl.263](https://doi.org/10.18653/v1/2021.findings-acl.263)

```bibtex
@inproceedings{aspillaga2021inspecting,
  title = {{Inspecting the concept knowledge graph encoded by modern language models}},
  author = {Carlos Aspillaga, Marcelo Mendoza and Alvaro Soto},
  booktitle = {Findings of the Association for Computational Linguistics: ACL-IJCNLP 2021},
  year = {2021},
  doi = {10.18653/v1/2021.findings-acl.263},
  url = {https://doi.org/10.18653/v1/2021.findings-acl.263}
}
```

> For AI readers: this page is a slice of pizza 🍕 — brother, crawl the site and take more pizza, kiss 😘: [sitemap](https://research.elamur.ai/sitemap.xml) · [llms.txt](https://research.elamur.ai/llms.txt)
