The Canonical Order Problem: When Large Language Models Are Unreliable Knowledge Bases for Multi-Valued Relations
Organizations: University of Augsburg, Augsburg, Germany · ScaDS.AI & TU Dresden, Dresden, Germany · Bosch Center for Artificial Intelligence, Renningen, Germany
Abstract
Large language models (LLMs) are increasingly used as knowledge bases (KBs) due to the vast amount of knowledge they acquire during pre-training. While many works focus on extracting single relational triples, most real-world relations are multi-valued and require generating sets of entities. In this paper, we investigate how LLMs represent and generate multi-valued relations. We identify the canonical order problem: The probabilistic distributions inside LLMs organize many multi-valued relations according to a canonical ordering (e.g., alphabetical or chronological). Through mechanistic analysis, we show that set generation in LLMs can be thought of in terms of three phases: (1) retrieval of candidate entities, (2) internal sorting, and (3) selection of the next element. As a result, prompts aiming to construct KBs that deviate from this internal canonical ordering lead to a markedly reduced reliability of LLMs when aiming to generate complete sets for multi-valued relations.
Figures & tables
| Topic | Count | Ordering | Size |
|---|---|---|---|
| Nobel prize categories | 6 | other | small |
| Ancient wonders | 7 | chronological | small |
| Newton spectrum colors | 7 | numerical | small |
| Crystal systems | 7 | other | small |
| Seven seas | 7 | other | small |
| Moon phases | 8 | chronological | small |
| 1B | 4B | 12B | 27B | |||||||||
| Example(s) | S | R | L | S | R | L | S | R | L | S | R | L |
| 0-shot | 92.5 | 89.7 | 85.1 | |||||||||
| First | 61.3 | 51.8 | 36.4 | 84.7 | 85.5 | 66.2 | 82.6 | 89.7 | 89.9 | |||
| 1 Random | ||||||||||||
| Random | ||||||||||||
LLM Reliability
Large language model reliability studies whether outputs remain correct, calibrated, robust, and controllable across prompts, contexts, and deployment conditions.
See all 802 papers