TerpreT:一种可能的程序归纳程序设计语言
TerpreT: A Probabilistic Programming Language for Program Induction
摘要:
我们研究归纳程序合成的机器学习公式;给定输入输出示例,我们尝试合成将输入映射到相应输出的源代码。我们的目标是开发基于神经网络和图形模型的新机器学习方法,并了解机器学习技术相对于传统替代方案的能力,例如基于程序设计语言社区的约束求解。我们的主要贡献是TerpreT,一个特定领域的语言表达程序合成问题的建议。TerpreT类似于概率程序设计语言:模型由程序表示的规范(随机变量的声明)和描述程序如何将输入映射到输出的解释器(将未知数连接到观察结果的模型)组成。推理任务是观察一组输入输出示例并推断底层程序。TerpreT有两个主要好处。首先,它可以快速探索一系列领域,程序表示和解释器模型。其次,它将模型规范与推理算法分离,允许不同推理方法之间的相似比较。从一个单一的TerpreT规范中,我们使用四个不同的后端自动执行推理。这些是基于梯度下降,线性规划(LP)松弛的图形模型,离散可满足性求解,和草图程序合成系统。我们通过开发几种解释器模型并在替代推理算法之间进行实证比较来说明TerpreT的价值。我们的主要经验发现是,约束求解器占主导地位的梯度下降和LP为基础的配方。最后,我们建议机器学习社区在程序合成方面取得进展。
英文摘要:
We study machine learning formulations of inductive program synthesis; given input-output examples, we try to synthesize source code that maps inputs to corresponding outputs. Our aims are to develop new machine learning approaches based on neural networks and graphical models, and to understand the capabilities of machine learning techniques relative to traditional alternatives, such as those based on constraint solving from the programming languages community. Our key contribution is the proposal of TerpreT, a domain-specific language for expressing program synthesis problems. TerpreT is similar to a probabilistic programming language: a model is composed of a specification of a program representation (declarations of random variables) and an interpreter describing how programs map inputs to outputs (a model connecting unknowns to observations). The inference task is to observe a set of input-output examples and infer the underlying program. TerpreT has two main benefits. First, it enables rapid exploration of a range of domains, program representations, and interpreter models. Second, it separates the model specification from the inference algorithm, allowing like-to-like comparisons between different approaches to inference. From a single TerpreT specification we automatically perform inference using four different back-ends. These are based on gradient descent, linear program (LP) relaxations for graphical models, discrete satisfiability solving, and the Sketch program synthesis system. We illustrate the value of TerpreT by developing several interpreter models and performing an empirical comparison between alternative inference algorithms. Our key empirical finding is that constraint solvers dominate the gradient descent and LP-based formulations. We conclude with suggestions for the machine learning community to make progress on program synthesis.
机构、总结、中文摘要均由AI分析而来,可能存在错误,请以论文正文为准。