https://github.com/mrvplusone/escher-scala
Recursive Program Synthesis using input-output examples
https://github.com/mrvplusone/escher-scala
automated-programming program-synthesis programming-by-example
Last synced: 10 months ago
JSON representation
Recursive Program Synthesis using input-output examples
- Host: GitHub
- URL: https://github.com/mrvplusone/escher-scala
- Owner: MrVPlusOne
- Created: 2017-04-02T08:02:28.000Z (about 9 years ago)
- Default Branch: master
- Last Pushed: 2017-05-25T06:10:20.000Z (about 9 years ago)
- Last Synced: 2025-04-04T14:51:13.441Z (about 1 year ago)
- Topics: automated-programming, program-synthesis, programming-by-example
- Language: Scala
- Homepage:
- Size: 3.56 MB
- Stars: 7
- Watchers: 2
- Forks: 5
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# Escher-Scala
Example-Driven Recursive Program Synthesis
This repository contains the source code of this thesis [Oracle-free Synthesis of Recursive Programs](documentation/AscendRec-en.pdf).
The codebase implements two algorithms: **TypedEscher** and **AscendRec**
**TypedEscher** is a Scala implementation of the *Escher* algorithm, described in this paper [Recursive Program Synthesis(CAV'13)](https://www.microsoft.com/en-us/research/publication/recursive-program-synthesis/), with the addition of a polymorphic static type system and other type-related optimizations to improve searching efficiency.
**AscendRec** is a new algorithm based on *TypedEscher*, but unlike *TypedEscher*, which requires the user to provide additional input-output examples during synthesis, *AscendRec* dose not need any additional examples to work.
### How to use the source code
Simply download or clone this project and run [sbt](http://www.scala-sbt.org) from within the root directory.
To compile and run the benchmark suits, use `sbt run` and choose `RunTypedEscher` or `RunAscendRec` as the Main Class.
### Results taken from the [thesis](documentation/AscendRec-en.pdf).
See full output logs in [result_TypedEscher.txt](documentation/text_results/result_TypedEscher.txt) and [result_AscendRec.txt](documentation/text_results/result_AscendRec.txt)


### Some Synthesized Programs(TypedEscher):
- Duplicate each element of a list

- Cartesian product of two lists

- Square of naturals

- Remove adjacent duplicates in a list

- Remove all duplicates in a list (synthesized without using additional components)
