This repository contains code that goes with the paper: Neural Guided Constraint Logic Programming for Program Synthesis https://papers.nips.cc/paper/7445-neural-guided-constraint-logic-programming-for-program-synthesis
This repository contains an implementation of miniKanren where the constraint trees are represented transparently. We add scaffolding code to show how to drive miniKanren using an external agent in Python. We provide Recurrent Neural Network (RNN) and Graph Neural Network (GNN) agents as examples. The implementations of the RNN and GNN are consistent with the models described in the paper .
The following files contain an implementation of miniKanren where the constraint trees are represented transparently, and a python interface for interacting with a miniKanren process.
|transparent implemenation of minikanren
|definition of evalo, a relational interpreter
|build queries annotated with ground truth
|compute ground truth outputs for queries
|interaction process for python to talk to
|python interface for scheme interaction
|helper for parsing lisp in python
The following files contain neural network agents that can drive miniKanren's search.
|helper for working with constraints
|parsing constraints for RNN model
|forward pass for RNN model
|parsing constraints for GNN model
|forward pass for GNN model
The following files contain the test problems used in the paper.
|held out tree manipulation problems
 NeurIPS 2018 Neural Guided Constraint Logic Programming for Program Synthesis
 ICLR 2018 Workshop: with slightly less detail (4 pages)
 Lisa Zhang's Master's Thesis: with slightly more detail (23 pages)
 More information about miniKanren