HackerPapers

arXiv:2504.07157cs.NE

GAAPO: Genetic Algorithmic Applied to Prompt Optimization

Xavier Sécheresse, Jacques-Yves Guilbert--Ly, Antoine Villedieu de Torcy

HN submission. Found in a submission link or body. Submitters do not count as commenters in the main ranking; a submission is not an endorsement.

Abstract

Large Language Models (LLMs) have demonstrated remarkable capabilities across various tasks, with their performance heavily dependent on the quality of input prompts. While prompt engineering has proven effective, it typically relies on manual adjustments, making it time-consuming and potentially suboptimal. This paper introduces GAAPO (Genetic Algorithm Applied to Prompt Optimization), a novel hybrid optimization framework that leverages genetic algorithm principles to evolve prompts through successive generations. Unlike traditional genetic approaches that rely solely on mutation and crossover operations, GAAPO integrates multiple specialized prompt generation strategies within its evolutionary framework. Through extensive experimentation on diverse datasets including ETHOS, MMLU-Pro, and GPQA, our analysis reveals several important point for the future development of automatic prompt optimization methods: importance of the tradeoff between the population size and the number of generations, effect of selection methods on stability results, capacity of different LLMs and especially reasoning models to be able to automatically generate prompts from similar queries... Furthermore, we provide insights into the relative effectiveness of different prompt generation strategies and their evolution across optimization phases. These findings contribute to both the theoretical understanding of prompt optimization and practical applications in improving LLM performance.

arXiv comments
26 pages, 9 figures
Journal reference
DOI
Subjects
cs.NENeural and Evolutionary Computing cs.LGMachine Learning

On Hacker News

No comments linking this paper were found in the collected sources. Found in 1 HN submission from Jul 2025 to Jul 2025. Open submission discussions.

Comments linking this paper, per year.

Discussed in comments0 threads

No comments linking this paper were found in the collected sources. Open submission discussions.

Submitted to Hacker News

  • GA and RL and prompt-driven agents

    Hi HN, I’ve been thinking about a new idea and would love to hear your thoughts. I’m exploring the concept of an AI agent that improves itself using reinforcement learning (RL) policies. The goal is to create an agent that can assist with programming, requirements engineering, or similar tasks that can be driven by LLMs. One of the main challenges is that RL typically requires a finite set of actions, whereas prompts for LLMs can be arbitrarily complex or open-ended. To address this, I’m…

Connected through shared HN threads, not inferred similarity or a recommendation.