First-order miniKanren representation: Great for tooling and search

semanticscholar(2019)

引用 3|浏览0
暂无评分
摘要
We present a first-order implementation of miniKanren that makes it easy to build a miniKanren debugger, and allows any other processes (including a human or a neural network) to guide the search. Typical miniKanren implementations use procedures to represent data structures like goals and streams. Instead, our implementation uses Racket structs, which are transparent, decomposable, manipulable, and not coupled with a particular search strategy. We obtain this first-order implementation by carefully applying defunctionalization rules to a higher-order implementation, deriving two compatible versions with the same search behavior and comparable performance. Decoupling the search in the first-order implementation makes it possible to analyze, transform, and optimize a miniKanren program, even while that program is running. We use a “human guided” search as a miniKanren debugger, and to demonstrate the breadth of supported search strategies. The flexibility in how we interpret goals and streams opens up possibilities for new tools, and we hope to inspire the community to build better miniKanren tooling.
更多
查看译文
AI 理解论文
溯源树
样例
生成溯源树,研究论文发展脉络
Chat Paper
正在生成论文摘要