🤖 AI Summary
In component-based program synthesis, precise logical specifications often yield an extremely sparse space of feasible solutions, rendering traditional approaches inefficient. This work proposes Liquid Tree Automata (LTA), which integrates a refinement-type-driven state-merging mechanism into tree automata for the first time. By leveraging subtyping constraints, LTA actively identifies and merges semantically equivalent states during search, thereby avoiding redundant exploration. The approach substantially improves synthesis efficiency, as demonstrated by Hegel—an implemented tool that successfully handles complex synthesis queries beyond the reach of current state-of-the-art tools—validating both its effectiveness and scalability.
📝 Abstract
Component-based synthesis (CBS) generates loop-free programs from library components to satisfy logical queries. While expressive specifications and precise queries simplify the solution space, they make finding feasible execution paths significantly more difficult for traditional CBS procedures. As constraints become more exact, the search must navigate an increasingly sparse space of valid paths. We address this challenge by reasoning about \emph{logical similarities} between exploration paths. We consider library methods equipped with refinement-type specifications, which enrich base types with logical qualifiers to precisely constrain the value space. To efficiently explore this space, we introduce Liquid Tree Automata (LTA), a novel tree automata variant whose construction is driven by refinement typing rules. LTAs leverage subtyping constraints to identify and eagerly merge semantically similar states during search. This merging avoids redundant exploration of equivalent paths, significantly improving synthesis efficiency. We implement this approach in a tool called Hegel. Our evaluation demonstrates that Hegel synthesizes solutions to complex queries that are beyond the reach of existing state-of-the-art tools.