Live data from Hacker News

AI learns to write its own code by stealing from other programs

newscientist.com

101–110 of 160 posts

Re: AI learns to write its own code by stealing from other programs

#102
post #45

“It could allow non-coders to simply describe an idea for a program and let the system build it” This is not a new thought. The problem with it, however, is that such a description would have to be very precise or else leave room for different interpretations which in turn could lead to very different programs being generated. In particular, as programmers know, it's often the edge cases that pose the main difficulty…

In automatic programming discussions, one commenter said long ago that we already have people that deal with English this precise: lawyers. Such a model would basically turn programmers into people writing legal documents that the AI then turned into programs.

Re: AI learns to write its own code by stealing from other programs

#103
post #45

“It could allow non-coders to simply describe an idea for a program and let the system build it” This is not a new thought. The problem with it, however, is that such a description would have to be very precise or else leave room for different interpretations which in turn could lead to very different programs being generated. In particular, as programmers know, it's often the edge cases that pose the main difficulty…

In automatic programming discussions, one commenter said long ago that we already have people that deal with English this precise: lawyers. Such a model would basically turn programmers into people writing legal documents that the AI then turned into programs.

We already have language lawyers for implementing compilers. I think the right solution is to take away most of the "convenience" features. Most people don't touch all of them anyway because they don't know how they would interact. But everyone joining a team would have to learn them.

Why do so many computer languages experience scope creep? Including C++ and JS.

Re: AI learns to write its own code by stealing from other programs

#105

Earlier quoted context omitted.

>I do wonder what will we do when computers do everything for us. Yeah, this is a pretty existential question that has been posed a lot around here. What do you do if you do not have to do anything? It is like vacation, forever. You are free to be lazy, or creative, or adventurous, or somewhere in between, but will you be happier? I have been between significant work for a few months and I am itching to do something…

> It is like vacation, forever. I guess that's one way to look at death from malnutrition, exposure or untreated illness. We can wax optimistic about what post-automation life could be like, but let's be honest: right now, unless you are an investor in companies that have automated or provide automation solutions, you are in absolutely no position to see 'vacation, forever' on the horizon for yourself or your childre…

Either we fix that, true, or there will be just far less people after a while. In the meantime, starvation may be a common "disease" in 1st world as well, just as it is already in the 3rd world.

It's just that automation needs many people. It is to fix the problem of mass production. If there are no consumer masses, there is no need for mass production and thus no need for automation.

But maybe the masses are just turned from consumers into products. That is what Google and Facebook already do today. Don't know If I would like to live in such a world. Already now I don't like it to be a Google product. Is that the choice, between starvation in freedom, or being nothing but a product, a second order slave?

Re: AI learns to write its own code by stealing from other programs

#106
post #58

Earlier quoted context omitted.

If you can describe something then you can just code it. I can see AI being used in an advanced IDE as an assistant. Just write your specs and let the AI build the app.

But wouldn't you agree that by the same line of reasoning, if you can spec it, you can code it? I mean, the difficulty lies in specifying what you want in such an unambiguous way that a program that fulfill the specification actually does what you had in mind originally.

Yes, and that difficulty has been lowered many times over the years as we create better programming languages, libraries, and tools. It is easier and quicker to unambiguously describe your program in python than it is in assembly. It is easier to write a web server using libraries than by writing the whole thing from scratch.

These advanced AIs would just be the next level of this, giving even easier ways to specify to a computer exactly what you want it to do.

Re: AI learns to write its own code by stealing from other programs

#107
post #45

“It could allow non-coders to simply describe an idea for a program and let the system build it” This is not a new thought. The problem with it, however, is that such a description would have to be very precise or else leave room for different interpretations which in turn could lead to very different programs being generated. In particular, as programmers know, it's often the edge cases that pose the main difficulty…

[deleted]

Re: AI learns to write its own code by stealing from other programs

#108

Earlier quoted context omitted.

If you can describe something then you can just code it. I can see AI being used in an advanced IDE as an assistant. Just write your specs and let the AI build the app.

making people in an industry more efficient at their jobs == job losses for that industry. if one programmer can now do the work of 5 with the help of an AI, companies will quickly be hiring less developers. yet everytime i mention this, im told that "software developers are the one job that will never be at risk of automation"

Open source has already started doing this to some degree. At my last few companies, we used open source projects as a base for many of our software.

Instead of having to hire multiple senior level developers, all they needed to do was hire one project manager (me) and a bunch of junior developers (which are much cheaper). This is because all of the engineering-level software was given out for free and the company only needs to make changes, which takes much less experienced employees.

Re: AI learns to write its own code by stealing from other programs

#110

Earlier quoted context omitted.

Doesn't TDD basically provide a spec? Write a test, then let the AI generate a program that passes the test. If the program is still buggy, you didn't write sufficient tests.

Tests are much more verbose than specs. Test validate existential properties, ie. there exist inputs where property P is true, but specs can also specify universal properties, ie. for all inputs property P is true. Static types also specify universal properties, which is why tests can't replace types, even in theory. But tests+types could be a type of spec.

Tests can constrain a problem enough so a human programmer can understand what was intended. In theory, many programs will pass the tests, but in practice most matching programs will be convoluted and in poor taste - they only pass the tests and not the general rules implied by the test cases. In other words, there are additional constraints implied by common-sense principles of software engineering.

Developing an AI that can infer a simple, tasteful set of general rules (and suitable types) from a small set of test cases is certainly hard but not theoretically impossible.

Post reply on HN