TaxonGPT: Taxonomic Classification Using Generative Artificial Intelligence

Haoyuan Huang, Teng Li, Zhixuan Wang, David Seldon, Allen G. RodrigobioRxiv 2024

Abstract To address the challenges of consistency and quality in taxonomic classifications, we have developed a Python program called TaxonGPT, that utilizes the natural language processing capabilities of generative artificial intelligence (gAI, specifically, ChatGPT-4o) to generate taxonomic descriptions and taxonomic keys. To counter the propensity for large language model gAIs to “hallucinate”, we use knowledge graph semantic representation and an error-checking module to ensure that accurate taxonomic descriptions and keys are obtained. In this paper, we describe how TaxonGPT embeds ChatGPT-4o’s responses as outputs. We also report on benchmark tests for accuracy, efficiency and reproducibility. These tests demonstrate that TaxonGPT excels in generating taxonomic keys and descriptions.

Introduction

The biological sciences are currently grappling with what is known as the "Taxonomic Impediment." Despite the urgent need to document biodiversity amidst a global extinction crisis, it is estimated that only 10% of the world's species have been formally described. Traditional taxonomic workflows are often bottlenecked by a dwindling number of human experts and the complexity of legacy software like DELTA (DEscription Language for TAxonomy), which requires significant training to master.

Generative Artificial Intelligence (gAI), particularly Large Language Models (LLMs) like ChatGPT-4o, offers a promising path toward automating the generation of taxonomic descriptions and keys. However, the tendency of these models to "hallucinate"—generating plausible but biologically inaccurate information—has limited their adoption in rigorous scientific contexts. To address these challenges, we present TaxonGPT, a Python-based framework that integrates LLMs with Knowledge Graph (KG) semantic representations and a dedicated error-checking module to ensure high-fidelity taxonomic outputs.

Methodology

TaxonGPT operates by bridging the gap between raw morphological data (Nexus matrices) and polished taxonomic products. The system architecture is divided into three primary functional modules: DESCRIBE, KEY, and CORRECT.

Workflow of TaxonGPT illustrating the DESCRIBE, KEY, and CORRECT modules.

As shown in Figure 1, the workflow begins with the ingestion of a Nexus matrix, which is then converted into a Knowledge Graph (KG). This KG acts as a "source of truth," providing a structured semantic representation of taxa and their associated characters.

  1. DESCRIBE Module: This component processes morphological data to generate natural language descriptions. It can produce outputs in various formats, such as lists or paragraphs, suitable for publication in taxonomic journals.
  2. KEY Module: This module automates the construction of dichotomous keys. It utilizes the LLM to identify optimal character states for splitting groups of species, creating a step-by-step identification guide.
  3. CORRECT Module: To mitigate hallucinations, the CORRECT module serves as a logic engine. It iteratively compares the LLM’s generated output against the initial Knowledge Graph. If discrepancies are detected—such as an incorrect character state assignment—the system records the error and prompts the LLM to regenerate the specific section, ensuring 100% alignment with the input data.

Experimental Evaluation

The performance of TaxonGPT was benchmarked using 11 diverse taxonomic datasets. These included six datasets from the DELTA database (e.g., Equisetum and Lycopodiales) and five from recent literature covering complex groups like Gymnosperms and Niphargidae. These datasets varied in complexity, with some featuring up to 75 distinct morphological characters, providing a robust test of the system's reasoning capabilities.

Results and Discussion

The evaluation demonstrated that TaxonGPT significantly outperforms traditional methods and standard web-based AI interfaces.

Accuracy and Reliability

TaxonGPT achieved 100% accuracy across all test datasets. A critical finding was the "Web vs. API" gap: while the standard web version of ChatGPT-4o saw accuracy drop to approximately 80% on complex keys, the TaxonGPT API-based approach maintained perfect fidelity. This underscores the necessity of the Knowledge Graph grounding and the iterative CORRECT loop.

Key Quality and Efficiency

The quality of the generated keys was measured using the $E_{Dicho}$ index, which evaluates the efficiency and balance of a dichotomous key. TaxonGPT achieved a score of 0.982, surpassing the 0.968 score produced by traditional DELTA software. Furthermore, the system is highly efficient, generating keys in an average of 88 seconds at a cost of less than $1 USD per project.

Reproducibility

LLMs are inherently non-deterministic, which can lead to inconsistent results. TaxonGPT addresses this by achieving a Consistency Score (CS) of 0.8, which is markedly higher than the 0.65 achieved by standard web-based AI interactions.

Conclusion

TaxonGPT represents a significant advancement in the application of generative AI to taxonomy. By grounding LLMs in structured knowledge and implementing automated error correction, the tool provides a reliable, efficient, and cost-effective solution for generating taxonomic descriptions and keys. While the current iteration faces a "ceiling" with datasets exceeding 30 species, it serves as a powerful augmentation tool for taxonomists. Future developments will focus on handling larger datasets and fine-tuning models on specialized biological literature to further enhance their domain-specific reasoning.

Summary updated

BibTeX
@misc{huang2024taxongpt,
  author = {Haoyuan Huang and Teng Li and Zhixuan Wang and David Seldon and Allen G. Rodrigo},
  title = {{TaxonGPT: Taxonomic Classification Using Generative Artificial Intelligence}},
  year = {2024},
  doi = {10.1101/2024.10.28.618575},
  howpublished = {bioRxiv},
}
Figure