Skip to content

Your Retrieval Embeddings Encode a Taxonomy Tree — PEEL Decodes It

THE ARGUMENT

Retrieval embeddings trained with Matryoshka representation learning already carry a coarse-to-fine ordering in their early dimensions, and a single 98K-parameter order-embedding probe can decode that ordering into explicit is-a edges without documents or target-domain edge labels.

On this page

3 retrieval encoders already sit in your stack, but nothing tells you whether their vectors encode a usable parent-child tree — so should the team buy hand-annotated taxonomy edges at all? The usual advice is binary: either pay annotators to read every term and mark which one is broader, or fine-tune an LLM per domain until it can generate a hierarchy. Both are expensive, and the second one does not travel well across domains. This paper offers a third option that is oddly cheap [1]. The authors observe that embeddings trained with Matryoshka representation learning, where every prefix of the vector is itself a usable representation, place coarse semantic information in early dimensions and fine detail later. That coarse-to-fine ordering happens to line up with the depth of gold taxonomies. A small probe can then read the ordering out as explicit is-a structure.

Longer prefixes separate finer categories

Matryoshka representation learning, MRL for short, trains a vector so that each leading prefix — the first 64 dimensions, the first 128, the first 512 — is independently usable for retrieval. That forces the model to pack broad semantic information into early coordinates and push detail toward the tail. The authors ask whether this engineered coarse-to-fine layout aligns with the shallow-to-deep levels of a human-built taxonomy. It does [1].

The measurement is kNN label purity: take each concept vector, find its 10 nearest neighbours, and check whether their category labels match. If short prefixes only separate medicine from law, while long prefixes separate cardiology from pulmonology, then prefix length tracks tree depth. The study covers three architecturally distinct MRL models: Nomic-embed-text-v1.5 (137M, BERT family), jina-embeddings-v3 (572M, XLM-R family), and Qwen3-Embedding (600M, decoder family), on the Wikipedia and arXiv taxonomic benchmarks.

On its own this proves little, because longer vectors simply hold more information and should score higher. Two controls carry the argument: a shuffled control that randomly permutes all dimensions before truncation, preserving information content while destroying the learned ordering, and a reverse control that keeps the last k tail dimensions. Prefix truncation beats both controls on all three encoders and both datasets, with the advantage concentrated in the early dimensions. At full dimensionality the prefix equals the whole embedding, so all three curves coincide by construction — which means the gap can only come from the learned early ordering.

Supporting evidence: effect size by taxonomy depth

As triangulation, the authors run a one-way ANOVA over every embedding dimension to measure how well labels separate at each depth, reporting mean eta-squared, an effect size that says how much of the variance the label explains. Cohen's conventional thresholds are .01 small, .06 medium, and .14 large.

Model (size, encoder)DataDepth 1Depth 2Depth 3
Nomic (137M)wiki.058.159.364
jina-v3 (572M)wiki.067.181.400
Qwen3 (600M)wiki.043.131.337
Nomic (137M)arXiv.039.122—
jina-v3 (572M)arXiv.078.205—
Qwen3 (600M)arXiv.039.131—

Read it this way: on Wikipedia the effects run small-to-medium at Depth 1 (.04–.07), medium at Depth 2 (.13–.18), and Cohen-large at Depth 3 (.34–.40); the shallower arXiv taxonomy, with two gold levels, moves in the same direction (.04–.08 and .12–.20). The depth ordering holds without exception across all six model-by-dataset sequences. The authors are careful to note that Wikipedia has 33, 875, and 7124 gold classes at those three depths, so the values index consistency of direction, not absolute cross-depth magnitude.

How PEEL turns an ordering into a tree in four steps

A finding is not a tool, so the authors propose PEEL, Peeling Embeddings to Extract Latent ontologies. It is deliberately minimal, because the premise is that the signal already sits in the frozen vectors [1].

  • Order-embedding probe. Freeze the retrieval vectors and train only a linear projection with ReLU, 98K parameters, output dimension 128, chosen by ablation. The loss enforces that a parent's coordinates are no larger than its child's in every dimension, which encodes the asymmetric is-a relation that symmetric contrastive losses cannot express.
  • Random truncation training. At each step, sample a length from 64, 128, 256, 384, 512, and 768, truncate all embeddings to it, and zero-pad back to 768. One probe then serves every resolution; at inference the best dimensionality is selected per dataset.
  • Minimum spanning arborescence. Score each node pair by a violation measure, the amount by which the parent's coordinates exceed the child's, then run Chu-Liu/Edmonds to get an optimal rooted tree with exactly N minus 1 edges and no threshold to tune.
  • DAG expansion. Real ontologies are often polyhierarchical, so a tree undercounts. Remaining node pairs are ranked by violation score and the lowest-violation edges are added greedily up to a budget.

The contrast with prior hierarchy encoders is sharp. HiTs retrains the entire encoder, between 22M and 109M parameters, under a hierarchy-aware objective. PEEL trains 98K parameters and leaves the embeddings untouched.

Results on two OLLM benchmarks, and what is actually being compared

Evaluation runs on the two OLLM benchmarks, Wikipedia and arXiv. The input is a concept vocabulary only, with no documents, which matters because inducing structure from a bare term list is both harder and far cheaper than letting a model read a corpus. PEEL reaches Graph F1 of .885 on Wikipedia and .931 on arXiv; Cont. F1 is reported as the other structure-sensitive metric.

On transfer, the paper reports zero-shot movement to a new domain with no target-edge supervision. Read the wording carefully: the probe is still trained once on source-domain gold edges. What is removed is annotation in the target domain, not annotation altogether.

One comparison must be flagged. The end-to-end OLLM pipeline discovers concepts and induces structure from document corpora jointly, and the paper reports it as a cross-task reference rather than a like-for-like baseline. So .885 and .931 measure one thing: recovering structure over a given concept set, not building an ontology from scratch.

When this method does not apply

The method fails when the embeddings were not trained with MRL. Without the property that every prefix is independently usable, the prefix-depth alignment that the whole argument rests on does not exist. It also does not apply when you need concept discovery: the concept set is given, and only structure is induced. In the LLMs4OL three-task framing, PEEL covers taxonomy discovery and leaves term typing and non-taxonomic relation extraction out of scope.

Depth matters for reading the scores. arXiv's .931 exceeds Wikipedia's .885, but arXiv's gold taxonomy has at most two levels while Wikipedia has three, so the two numbers are not directly comparable. A tree holds exactly N minus 1 edges, and polyhierarchy depends on greedy expansion under an edge budget, which trades recall for precision in a way the budget controls. The eta-squared table is supporting evidence only; with class counts spanning two orders of magnitude across depths, no single value should be read as proof of how many levels a model learned.

The honest summary: the paper shows that hierarchical signal inside retrieval embeddings is decodable, not that those embeddings are an ontology. Within that boundary it offers a starting point cheap enough to run before committing to annotation or fine-tuning [1].

References

  1. Peeling the Matryoshka: Extracting Ontological Structure from Retrieval Embeddings

Sign in to Padda

A code in your inbox. No password to remember.

Connecting to sign-in…