HiFo-Prompt: Prompting with Hindsight and Foresight for LLM-based Automatic Heuristic Design
Chentong Chen, Mengyuan Zhong, Ye Fan, Jialong Shi, Jianyong Sun

TL;DR
HiFo-Prompt introduces a dual prompting framework for LLM-based automatic heuristic design that adaptively guides search and distills successful heuristics, significantly improving performance and efficiency in evolutionary computation tasks.
Contribution
The paper presents HiFo-Prompt, a novel framework combining foresight and hindsight prompts to enhance LLM-guided heuristic design in evolutionary algorithms.
Findings
Outperforms state-of-the-art LLM-based AHD methods
Generates higher-quality heuristics
Achieves faster convergence and better query efficiency
Abstract
LLM-based Automatic Heuristic Design (AHD) within Evolutionary Computation (EC) frameworks has shown promising results. However, its effectiveness is hindered by the use of static operators and the lack of knowledge accumulation mechanisms. We introduce HiFo-Prompt, a framework that guides LLMs with two synergistic prompting strategies: Foresight and Hindsight. Foresight-based prompts adaptively steer the search based on population dynamics, managing the exploration-exploitation trade-off. In addition, hindsight-based prompts mimic human expertise by distilling successful heuristics from past generations into fundamental, reusable design principles. This dual mechanism transforms transient discoveries into a persistent knowledge base, enabling the LLM to learn from its own experience. Empirical results demonstrate that HiFo-Prompt significantly outperforms state-of-the-art LLM-based AHD…
Peer Reviews
Decision·ICLR 2026 Poster
1. The motivation of this paper is clear and reasonable. The design ideas of global guidance and the insight pool are interesting and inspiring. 2. The similarity-based diversity discussion for the insight pool is conceptually stimulating. 3. The paper is clearly written and well organized, making it easy to follow.
1. I have concerns about the novelty threshold. The Insight Pool’s novelty filtering relies on Jaccard similarity over token sets. While this removes near-duplicate sentences, such a pure text-based comparison cannot capture semantic overlap. For example, one insight might be expressed in different ways. Since this novelty threshold is crucial for ensuring diversity, I worry this design may harm the actual effectiveness of the diversity mechanism. 2. The combination of a usage penalty and a r
1. The proposed method is well motivated and outperforms recent LLM-based AHD baselines across several tasks. 2. The design details are well presented. 3. The limitations and future directions are clearly analyzed.
1. For TSP step-by-step construction (i.e., Table 1), Appendix B.1 states that HiFo-Prompt involves LLM calls at inference time, however, it is unclear to me that whether such strategy also applies to the baselines. Please disambiguate: (a) If baselines also call the LLM at inference, please explain why HiFo-Prompt’s runtime is longer; (b) If they do not, please also report HiFo-Prompt under the same inference protocol for fair comparisons. 2. The main text claims TSPLIB results are in Appendix
- The idea of tracking both local and global evolution dynamics via specialized modules is interesting and well executed - Useful ablation studies - Strong performance with few function evaluations
1. Seed insights are required by the method. Importantly, these insights could significantly improve generation quality: “Design adaptive hybrid meta-heuristics synergistically fusing multiple search paradigms and dynamically tune operator parameters based on search stage or problem features.” particularly is a high-quality handcrafted prompt that can have a substantial effect on the generation. For fairness of comparison, one should provide the same information in the prompt of other baselines,
Videos
No videos yet. Explain this paper in a talk, walkthrough, or lecture? Add one.
Taxonomy
TopicsManufacturing Process and Optimization · Model-Driven Software Engineering Techniques · AI-based Problem Solving and Planning
