HIPO: A Hierarchical Prompt Optimization Framework with Task Awareness and Fine-Grained Debugging

Lu Qi, Lei Chai, Hongrui Yu, Binhang Qi, Hailong Sun


Abstract
Large Language Models (LLMs) have demonstrated remarkable capabilities across diverse natural language processing tasks. However, their performance often hinges on carefully designed prompts, whose creation requires substantial human effort. While numerous automatic prompt optimization techniques have been proposed, existing methods typically apply the same prompt across all samples within a dataset, ignoring variation in sample difficulty. To address these limitations, we propose HIPO, a HIerarchical Prompt Optimization framework that shifts the paradigm from dataset-level to sample-level optimization. Our framework first employs a lightweight router model, trained offline, to predict the difficulty of each sample at test time. Based on this prediction, HIPO dynamically selects a prompt from a five-tiered hierarchy, tailoring complexity to sample difficulty. Furthermore, two refinement stages—Task Description Prompt Refine and Attribution-Based Prompt Refine—enhance generalizability and fine-grained optimization. Extensive experiments on 27 tasks demonstrate that HIPO outperforms all baselines, achieving state-of-the-art performance on 25% more tasks than the strongest baseline. Cost analysis further demonstrates substantial efficiency gains, reducing API calls, token consumption, and overall cost by 1.2× to 80×. Our implementation is publicly available at https://github.com/LuQiCode/HIPO.
Anthology ID:
2026.findings-acl.996
Volume:
Findings of the Association for Computational Linguistics: ACL 2026
Month:
July
Year:
2026
Address:
San Diego, California, United States
Editors:
Maria Liakata, Viviane P. Moreira, Jiajun Zhang, David Jurgens
Venue:
Findings
SIG:
Publisher:
Association for Computational Linguistics
Note:
Pages:
19928–19947
Language:
URL:
https://preview.aclanthology.org/ingest-acl/2026.findings-acl.996/
DOI:
Bibkey:
Cite (ACL):
Lu Qi, Lei Chai, Hongrui Yu, Binhang Qi, and Hailong Sun. 2026. HIPO: A Hierarchical Prompt Optimization Framework with Task Awareness and Fine-Grained Debugging. In Findings of the Association for Computational Linguistics: ACL 2026, pages 19928–19947, San Diego, California, United States. Association for Computational Linguistics.
Cite (Informal):
HIPO: A Hierarchical Prompt Optimization Framework with Task Awareness and Fine-Grained Debugging (Qi et al., Findings 2026)
Copy Citation:
PDF:
https://preview.aclanthology.org/ingest-acl/2026.findings-acl.996.pdf
Checklist:
 2026.findings-acl.996.checklist.pdf