Hierarchical Text Classification with LLM-Refined Taxonomies

Golde, Jonas, Jedema, Nicolaas, Krishnan, Ravi, Le, Phong

–arXiv.org Artificial Intelligence 

Hierarchical text classification (HTC) depends on taxonomies that organize labels into structured hierarchies. However, many real-world taxonomies introduce ambiguities, such as identical leaf names under similar parent nodes, which prevent language models (LMs) from learning clear decision boundaries. In this paper, we present TAXMORPH, a framework that uses large language models (LLMs) to transform entire taxonomies through operations such as renaming, merging, splitting, and reordering. Unlike prior work, our method revises the full hierarchy to better match the se-Figure 1: Human-curated taxonomies used in hierarchimantics encoded by LMs. Experiments acrosscal text classification (HTC) are often suboptimal due to three HTC benchmarks show that LLM-refinedinconsistencies or ambiguities. TAXMORPH transforms taxonomies consistently outperform human-these taxonomies into structures that better align with curated ones in various settings up to +2.9pp. in F1. the internal representations of language models, leading to improved performance in HTC tasks. To better understand these improvements, we compare how well LMs can assign leaf nodes to parent nodes and vice versa across human-structures manifest in taxonomies, ontologies, and curated and LLM-refined taxonomies. We findknowledge bases (Vrandeciˇ c and Krötzsch, 2014; that human-curated taxonomies lead to more Lehmann et al., 2015; Heist and Paulheim, 2021).