论文标题
熵最佳玻尔兹曼采样器的自动编译时间合成
Automatic compile-time synthesis of entropy-optimal Boltzmann samplers
论文作者
论文摘要
我们提出了一个名声,用于自动编译Haskell中代数数据类型的多参数Boltzmann采样器。我们的框架使用模板haskell来合成有效的熵 - 最佳采样器,从而生成用户指定的代数数据类型的随机实例。用户可以通过纯净的声明性接口来控制结果分布。例如,用户可以控制生成对象的平均大小和构造函数。我们通过原型通用玻璃体脑库来说明我们的框架的有效性,以表明可以控制成千上万个ADT系统中的数千个不同参数。我们的原型框架合成了Boltzmann采样器,能够快速生成数百万中大小的随机对象。
We present a famework for the automatic compilation of multi-parametric Boltzmann samplers for algebraic data types in Haskell. Our framework uses Template Haskell to synthesise efficient, entropy-optimal samplers generating random instances of user-declared algebraic data types. Users can control the outcome distribution through a pure, declarative interface. For instance, users can control the mean size and constructor frequencies of generated objects. We illustrate the effectiveness of our framework through a prototype generic-boltzmann-brain library showing that it is possible to control thousands of different parameters in systems of tens of thousands of ADTs. Our prototype framework synthesises Boltzmann samplers capable of rapidly generating random objects of sizes in the millions.