News for hackers. Stuff that matters.
Re:AI learns to write its own code by stealing from other pr... by a-priori on Thursday February 23, 2017 @12:20PM (#13715646)
A few years ago I read a post by Bob Martin about how you can solve code kata problems by applying a sequence of 'transformations' to pass one test at a time. His method is very mechanical... so mechanical, in fact, that I think it may be possible to automate it.

So I started tinkering with the concept, and I've got a bit of a start on it here:

https://github.com/michaelmelanson/autocoder

What's there is very rudimentary. The main class is a good place to start.

Basically I'm building up a library of transformations that can describe solutions to kata problems (the 'word wrap' one currently). The next step is to create a search algorithm to derive an ordered sequence of transformations from that library to pass an ordered sequence of tests.

Re:AI learns to write its own code by stealing from other pr... by hcs on Thursday February 23, 2017 @12:52PM (#13715970)
You might find Perelman et al's "Test-Driven Synthesis" paper interesting, it also cites that post as inspiration.

http://homes.cs.washington.edu/~djg/papers/tds-pldi2014.pdf