Microsoft Research, University of Cambridge work on DeepCoder to write its own code

February 24, 2017
by Nancy Owano

(Tech Xplore)—It's been said that an artificial intelligence dream has been building systems that can write computer programs. A University of Cambridge and Microsoft Research team is on a direct path.

They have a paper describing their work on DeepCoder. It is an artificial intelligence system they built and it is a machine learning system with the ability to write its own code.

But how? Matt Reynolds in New Scientist said Wednesday:

"DeepCoder uses a technique called program synthesis: creating new programs by piecing together lines of code taken from existing software – just like a programmer might. Given a list of inputs and outputs for each code fragment, DeepCoder learned which pieces of code were needed to achieve the desired result overall."

The paper "DeepCoder: Learning to write programs" is by Matej Balog, University of Cambridge, and Alexander Gaunt, Marc Brockschmidt, Sebastian Nowozin, and Daniel Tarlow from Microsoft Research.

The authors said that in their work, they are proposing two main ideas, "(1) learn to induce programs; that is, use a corpus of program induction problems to learn strategies that generalize across problems, and (2) integrate neural network architectures with search-based techniques rather than replace them."

The limitations in their work: "First, the programs we can synthesize are only the simplest problems on programming competition websites and are simpler than most competition problems. Many problems require more complex algorithmic solutions like dynamic programming and search, which are currently beyond our reach.''

Still, they said that "Deep-Coder represents a promising direction forward, and we are optimistic about the future prospects of using machine learning to synthesize programs."

The programs were inspired by simple tasks appearing on real programming competition websites, they said, and were intended to illustrate the expressive power of their Domain Specific Language (DSL). The authors also provided a section showing example programs in the DSL, with inputoutput examples and descriptions.

(They defined DSLs as "programming languages that are suitable for a specialized domain but are more restrictive than full-featured programming languages." They said that their DSL "is loosely inspired by query languages such as SQL or LINQ, where high-level functions are used in sequence to manipulate data.")

How could their DeepCoder be of practical use?

Eric David in SiliconANGLE: "The researchers' ultimate goal is for non-coders to be able to tell DeepCoder exactly the type of program they need, and then let the AI handle the rest, greatly reducing development time and cost."

New Scientist similarly remarked that "This kind of approach could make it much easier for people to build simple programs without knowing how to write code."

MSPoweruser said that "the software can take requirements by the developer, search through a massive database of code snippets and deliver working code in seconds, a significant advance in the state of the art in program synthesis."

There is also the maintenance problem. Humans have enough trouble maintaining programs written by other humans. I might think that machine generated code would be even more obtuse. Of course you might automate maintenance as well. This trend would serve to remove humans ever farther from an understanding of how tools essential to their survival work. Then again you could design an AI to explain this to people...and so it goes.

Please sign in to add a comment.
Registration is free, and takes less than a minute.
Read more

Click here to reset your password.
Sign in to get notified via email when new comments are made.