Symbolic Prompt Program Search: A Structure-Aware Approach to Efficient Compile-Time Prompt Optimization (2404.02319v2)
Abstract: In many modern LLM applications, such as retrieval augmented generation, prompts have become programs themselves. In these settings, prompt programs are repeatedly called with different user queries or data instances. A big practical challenge is optimizing such prompt programs. Recent work has mostly focused on either simple prompt programs or assumed that the general structure of a prompt program is fixed. We introduce SAMMO, a framework to perform symbolic prompt program search for compile-time optimizations of prompt programs. SAMMO represents prompt programs on a symbolic level which allows for a rich set of transformations that can be searched over during optimization. We show that SAMMO generalizes previous methods and improves the performance of complex prompts on (1) instruction tuning, (2) RAG pipeline tuning, and (3) prompt compression, across several different LLMs. We make all code available open-source at https://github.com/microsoft/sammo .
- Task-oriented dialogue as dataflow synthesis. TACL.
- Leveraging code to improve in-context learning for semantic parsing.
- Language models are few-shot learners. NeurIPS.
- Instructzero: Efficient instruction optimization for black-box large language models.
- Batch prompting: Efficient inference with large language model apis.
- Promptbreeder: Self-referential self-improvement via prompt evolution.
- Mixtral of experts.
- LLMLingua: Compressing prompts for accelerated inference of large language models. In EMNLP.
- Hoyoun Jung and Kyung-Joong Kim. 2023. Discrete prompt compression with reinforcement learning.
- Dspy: Compiling declarative language model calls into self-improving pipelines.
- The power of scale for parameter-efficient prompt tuning. In EMNLP.
- Compressing context to enhance inference efficiency of large language models. In EMNLP.
- Batchprompt: Accomplish more with less.
- Learning to compress prompts with gist tokens. In NeurIPS.
- GrIPS: Gradient-free, edit-based instruction search for prompting large language models. In EACL.
- Automatic prompt optimization with "gradient descent" and beam search.
- Guanghui Qin and Jason Eisner. 2021. Learning how to ask: Querying lms with mixtures of soft prompts. In NAACL.
- Regularized evolution for image classifier architecture search. In AAAI.
- Quantifying language models’ sensitivity to spurious features in prompt design or: How i learned to start worrying about prompt formatting.
- Beyond the imitation game: Quantifying and extrapolating the capabilities of language models. TMLR.
- Black-box tuning for language-model-as-a-service. In ICML.
- Llama 2: Open foundation and fine-tuned chat models.
- Super-naturalinstructions:generalization via declarative instructions on 1600+ tasks. In EMNLP.
- Building a semantic parser overnight. In ACL.
- Prompt compression and contrastive conditioning for controllability and toxicity reduction in language models. In EMNLP: Findings.
- Prompt engineering a prompt engineer.
- Did you read the instructions? Rethinking the effectiveness of task definitions in instruction learning. In ACL.
- Did you read the instructions? rethinking the effectiveness of task definitions in instruction learning.
- John M Zelle and Raymond J Mooney. 1996. Learning to parse database queries using inductive logic programming. In National Conference on Artificial Intelligence.
- Large language models are human-level prompt engineers.
- Tobias Schnabel (21 papers)
- Jennifer Neville (57 papers)