NeurIPS 2026Coming to NeurIPS?Explore papers, orals & directions

TELEClass: Taxonomy Enrichment and LLM-Enhanced Hierarchical Text Classification with Minimal Supervision

Yunyi Zhang, Ruozhen Yang, Xueqiang Xu, Rui Li, Jinfeng Xiao, Jiaming Shen, Jiawei Han

TL;DR

TELEClass is a novel framework for hierarchical text classification that requires only class names as supervision. By combining the general knowledge of Large Language Models (LLMs) with domain-specific features mined from unlabeled text, it trains a lightweight classifier that matches or exceeds GPT-4 performance while being thousands of times cheaper and faster to run.

What Problem Does This Paper Address?

Hierarchical Text Classification (HTC) involves organizing documents into a structured tree or graph of categories (e.g., classifying a product review under Health Care → Hair Care → Shampoo). This is significantly harder than "flat" classification because the label space is often huge, and distinguishing between fine-grained, "long-tail" classes is difficult.

Traditionally, solving this required massive human-annotated datasets, which are expensive to build. While LLMs like GPT-4 are great at zero-shot classification, they struggle with HTC for two reasons:

  1. Prompt Limits: You can't easily fit a taxonomy of hundreds of classes into a single prompt without losing structural context.
  2. Inference Cost: Querying an LLM for every single document in a massive web corpus is prohibitively slow and expensive.

Existing "weakly-supervised" methods try to use only class names, but they often ignore the rich, domain-specific information hidden in the unlabeled corpus itself.

Methods

The authors propose TELEClass (Taxonomy Enrichment and LLM-Enhanced weakly-supervised hierarchical text Classification). The framework follows a four-step pipeline to distill LLM intelligence into a deployable local model:

  1. LLM-Enhanced Core Class Annotation: To avoid overwhelming the LLM, TELEClass uses a top-down tree search to identify a small set of candidate classes for each document. It then asks the LLM to pick the "core classes" that best describe the text.
  2. Corpus-Based Taxonomy Enrichment: The system mines the unlabeled corpus for phrases and ranks them based on popularity, distinctiveness (how well they separate a class from its "siblings"), and semantic similarity. This enriches the taxonomy with domain-specific keywords (e.g., adding "Batiste Dry" to the Shampoo class).
  3. Core Class Refinement: Using the enriched keywords, the system creates better embeddings for documents and classes. It refines the initial LLM labels by identifying the "similarity gap"—the point where class relevance drops off sharply.
  4. Path-Based Data Augmentation: To ensure the classifier learns even the rarest classes, TELEClass uses an LLM to generate synthetic documents for every distinct path in the taxonomy. Crucially, it uses the full path (e.g., Hair Care → Shampoo) to ensure the LLM generates contextually correct text, avoiding confusion with other types of shampoo (like pet shampoo).
Figure 2: Overview of the TELEClass framework.

Finally, a simple BERT-based matching network is trained on this high-quality pseudo-labeled data.

Datasets

The authors evaluated TELEClass on two diverse benchmarks:

  • Amazon-531: Product reviews categorized into a 3-layer taxonomy with 531 labels.
  • DBPedia-298: Wikipedia articles organized into a 3-layer taxonomy with 298 labels.
Table 1: Datasets overview.

Key Insights and Ideas

  • The Power of Hybrid Knowledge: LLMs provide broad, general semantic understanding, but the unlabeled corpus provides the "ground truth" of how terms are actually used in a specific domain. Combining them is more effective than using either alone.
  • Structure-Aware Prompting: By guiding the LLM through the taxonomy hierarchy rather than showing it everything at once, the authors achieved much higher annotation accuracy.
  • Efficiency via Distillation: The "aha moment" is that you don't need to run an LLM at inference time. By using the LLM as a high-quality "teacher" to label and generate data, you can train a BERT-base model that is just as accurate but significantly more practical for production.

Key Results

TELEClass significantly outperformed previous weakly-supervised baselines and even beat zero-shot LLM prompting in many scenarios:

  • Accuracy: On DBPedia-298, TELEClass achieved an Example-F1 of 0.8633, crushing GPT-3.5 (0.4816) and even GPT-4 (0.6054).
  • Cost & Speed: For the DBPedia test set, GPT-4 would cost an estimated $2,500 and take 1,000 minutes. TELEClass cost less than $1 and finished in 7 minutes.
  • Ablation: The authors showed that both LLM-based and corpus-based enrichment are vital; removing either led to a noticeable drop in performance.

Limitations and Future Work

The authors acknowledge a few hurdles:

  • Keyword Bias: Like all term-based methods, TELEClass can be tricked by "distractor" words. For example, a review mentioning a "glycolic treatment" might be misclassified as Health Care because of the word "treatment," even if it's actually a Beauty product.
  • Private Domains: If the LLM hasn't seen the specific domain during its training (e.g., highly specialized medical or legal documents), the initial annotation step might fail.
  • Scaling: While 500+ classes is impressive, real-world taxonomies can have millions of nodes. Scaling the enrichment and generation process to that level remains a challenge for future research.

Summary updated

BibTeX
@inproceedings{zhang2024teleclass,
  author = {Yunyi Zhang and Ruozhen Yang and Xueqiang Xu and Rui Li and Jinfeng Xiao and Jiaming Shen and Jiawei Han},
  title = {{TELEClass: Taxonomy Enrichment and LLM-Enhanced Hierarchical Text Classification with Minimal Supervision}},
  booktitle = {The Web Conference},
  year = {2024},
}
Figure