29 November 2025 in Computers in Biology and Medicine
Implementing pharmacogenomics (PGx) in the healthcare system faces several challenges. These include limited education among healthcare professionals and restricted patient awareness of the benefits of genetic testing. Generative AI offers a promising solution by generating tailored content. It also provides interactive clinical decision support to help bridge the knowledge gap. This study introduces a Hierarchical Retrieval-Augmented Generation (HRAG) framework for anticancer drugs (5-fluorouracil, capecitabine, and tamoxifen) to reflect the relationships between PGx documents. HRAG organizes the PGx guidelines into hierarchical tree structures, treating each guideline at the same level. Documents were chunked into passages, which were represented as leaf nodes. We evaluated the model using PGxQA dataset, based on RAGAS scores and human evaluation. HRAG and RAG models showed lower performance in PGxQA categories requiring precise numerical or entity matching, such as allele definition. They performed better in categories focused on textual reasoning, such as phenotype-to-guideline tasks. In contrast, HRAG significantly outperformed RAG in guideline-related tasks, demonstrating higher context precision, context recall, and accuracy (F1). Specifically, in the phenotype-to-guideline category, HRAG achieved an F1 score of 0.89, while RAG scored 0.80 (p-value = 9×10-4). These findings suggest that the HRAG framework could contribute to the development of a PGx AI assistant. It may help narrow the knowledge gap and facilitate the broader adoption of PGx.