English

HYSYNTH: Context-Free LLM Approximation for Guiding Program Synthesis

Programming Languages 2024-11-04 v2 Artificial Intelligence

Abstract

Many structured prediction and reasoning tasks can be framed as program synthesis problems, where the goal is to generate a program in a domain-specific language (DSL) that transforms input data into the desired output. Unfortunately, purely neural approaches, such as large language models (LLMs), often fail to produce fully correct programs in unfamiliar DSLs, while purely symbolic methods based on combinatorial search scale poorly to complex problems. Motivated by these limitations, we introduce a hybrid approach, where LLM completions for a given task are used to learn a task-specific, context-free surrogate model, which is then used to guide program synthesis. We evaluate this hybrid approach on three domains, and show that it outperforms both unguided search and direct sampling from LLMs, as well as existing program synthesizers.

Keywords

Cite

@article{arxiv.2405.15880,
  title  = {HYSYNTH: Context-Free LLM Approximation for Guiding Program Synthesis},
  author = {Shraddha Barke and Emmanuel Anaya Gonzalez and Saketh Ram Kasibatla and Taylor Berg-Kirkpatrick and Nadia Polikarpova},
  journal= {arXiv preprint arXiv:2405.15880},
  year   = {2024}
}

Comments

Accepted at NeurIPS 2024

R2 v1 2026-06-28T16:39:33.528Z