Program synthesis -- the automatic generation of code given a specification -- is one of the most fundamental tasks in artificial intelligence (AI) and the dream of many programmers. Numerous synthesizers have been developed for program synthesis, offering different approaches to the exponentially growing program space. Although such state-of-the-art tools exist, reusing and adapting them remains tedious and time-consuming. We propose Herb.jl, a unifying program synthesis library written in Julia, to address these issues. Since current methods share similar building blocks, we aim to break down the underlying algorithms into extendable, reusable subcomponents. To demonstrate the benefits of using Herb.jl, we show how to implement a simple problem and grammar, and how to solve it with just a few lines of code.
翻译:程序综合——根据规范自动生成代码——是人工智能(AI)中最基础的任务之一,也是许多程序员的梦想。目前已开发出众多程序综合工具,为指数级增长的程序空间提供了不同的解决方案。尽管存在此类先进工具,但复用和适配它们仍然繁琐且耗时。为此,我们提出了Herb.jl——一个用Julia编写的统一程序综合库,以解决这些问题。由于现有方法共享相似的构建模块,我们的目标是将底层算法分解为可扩展、可复用的子组件。为展示使用Herb.jl的优势,我们演示了如何实现一个简单问题与文法,并仅用几行代码即可解决该问题。