Property-Guided LLM Program Synthesis for Planning
André G. Pereira, Augusto B. Corrêa, Jendrik Seipp
NeurIPS page · OpenReview · alphaXiv · Open on the map
Category: LLM Agents, Evals & Benchmarks › Evolutionary Optimization with LLMs · Type: new method · Keywords: LLM program synthesis, property verification, counterexample feedback, automated planning, heuristic generation
Areas: Code & Coding Agents › Code Generation and Optimization › Code Generation; RL for LLMs & Agents › Language Model Agents › Language Model Optimization
Summary
Property-guided LLM program synthesis uses formal property checks and counterexamples to guide LLMs, drastically reducing program generation and evaluation cost while improving program quality.
Explained to a 5-year-old
We have a smart robot that writes little computer programs. It tries to make the programs work by checking if they follow simple rules. If a program breaks a rule, the robot shows it a picture of how it failed. This helps the robot see what went wrong and fix it quickly. So the robot can make good programs faster and with less effort.
Explained to a 5-year-old, longer
A computer program is a set of instructions that tell a machine what to do. Sometimes people want to write programs that solve puzzles or games. The robot that writes these programs usually just looks at a score, like how many tests it passes. A high score does not tell the robot why a program failed. The new idea is to give the robot a rule to check, like "the program must always move forward when possible." If the program breaks this rule, the robot gets a clear example of the mistake. This example shows exactly where the program went wrong. The robot can then fix the program and try again, learning from each failure. Because the robot knows the exact problem, it needs far fewer attempts to get a good program. This makes the whole process faster and uses less computer power. It also helps the robot create programs that are more reliable and useful. The approach works for many kinds of problems, as long as you can write a simple rule that the program should follow. By using these clear rules and feedback, the robot becomes a better assistant for writing computer code.
For a technical reader
The system evaluates candidate programs by verifying a formal property rather than just scoring them. When a program violates the property, a concrete counterexample is generated and fed back to the LLM, allowing early termination of evaluation. This iterative repair loop reduces both the number of generated programs and the computational cost of checking them. The approach is demonstrated on planning tasks, where synthesized heuristics achieve direct hill-climbing behavior and outperform prior methods in efficiency and success rate.
Problem
Existing LLM program synthesis methods rely on simple numeric scores that do not explain why a program fails, forcing the generation of many candidates and high evaluation cost.
Method
The approach checks candidate programs against a formally defined property; when a violation occurs, a concrete counterexample is provided to the LLM, enabling early stopping and iterative repair.
Results
The synthesized heuristics are effective on virtually all test tasks, generating on average seven times fewer programs per domain than prior methods, solving more tasks without search, and requiring orders of magnitude less evaluation computation.
Contributions
A framework that leverages formal property checks and counterexample feedback to guide program generation, reducing synthesis and evaluation cost while improving quality.
Practical relevance
It enables more efficient and higher-quality program synthesis for any domain where verifiable properties can be defined, reducing computational demands.
This page was written by language models from the title and abstract of each paper, and the answers were checked by two other models. It can be wrong: check the paper itself. Suggest a correction