arXivDaily arXiv每日学术速递 周一至周五更新
arXiv 1804.04152cs.PL
收藏

用于程序合成的学习抽象

Learning Abstractions for Program Synthesis

Xinyu Wang, Greg Anderson, Isil Dillig, K. L. McMillan

摘要:

许多示例引导的程序合成技术使用抽象来修剪搜索空间。虽然基于抽象的合成已经被证明是非常强大的,但领域专家需要提供一个合适的抽象领域,以及每个DSL构造的抽象Transformers。然而,提出有用的抽象可能是不平凡的,因为它需要领域专业知识和关于合成器的知识。在本文中,我们提出了一种新的技术,用于学习抽象,是有用的实例化一个一般的合成框架在一个新的领域。给定一个DSL和一小部分训练问题,我们的方法使用树插值来推断可重用的谓词模板,从而加快给定域中的合成。我们的方法还学习合适的抽象Transformers,通过解决某种二阶约束求解问题的数据驱动的方式。我们在一个名为ATLAS的工具中实现了所提出的方法,并在BLAZE元合成器的背景下对其进行了评估。我们的评估表明,(a)ATLAS可以从很少的训练问题中学习有用的抽象域和Transformers,(b)与手工制作的抽象相比,ATLAS学习的抽象允许BLAZE实现更好的结果。

英文摘要:

Many example-guided program synthesis techniques use abstractions to prune the search space. While abstraction-based synthesis has proven to be very powerful, a domain expert needs to provide a suitable abstract domain, together with the abstract transformers of each DSL construct. However, coming up with useful abstractions can be non-trivial, as it requires both domain expertise and knowledge about the synthesizer. In this paper, we propose a new technique for learning abstractions that are useful for instantiating a general synthesis framework in a new domain. Given a DSL and a small set of training problems, our method uses tree interpolation to infer reusable predicate templates that speed up synthesis in a given domain. Our method also learns suitable abstract transformers by solving a certain kind of second-order constraint solving problem in a data-driven way. We have implemented the proposed method in a tool called ATLAS and evaluate it in the context of the BLAZE meta-synthesizer. Our evaluation shows that (a) ATLAS can learn useful abstract domains and transformers from few training problems, and (b) the abstractions learned by ATLAS allow BLAZE to achieve significantly better results compared to manually-crafted abstractions.

机构、总结、中文摘要均由AI分析而来,可能存在错误,请以论文正文为准。

↑