News for hackers. Stuff that matters.
Re:GitHub Copilot as open source code laundering? by tyingq on Wednesday June 30, 2021 @09:21AM (#27688163)
"We found that about 0.1% of the time, the suggestion may contain some snippets that are verbatim from the training set"

If it's spitting out verbatim code 0.1% of the time, surely it's spitting out copied code where only trivial things are different at a much higher rate.

Trivial things meaning swapped order where order isn't important, variable/function names, equivalent ops like +=1 vs ++, etc.

Surely it's laundering some GPL code, for example, and effectively removing the license in a way that sounds fishy.

Re:GitHub Copilot as open source code laundering? by dwheeler on Wednesday June 30, 2021 @12:59PM (#27690822)
It's not just the GPL. Almost all open source software licenses require attribution; without that attribution, any copy is a license violation.

Whether or not the result is a license violation is tricky legal question. As always, IANAL.

Re:GitHub Copilot as open source code laundering? by tyingq on Wednesday June 30, 2021 @06:21PM (#27694133)
I did say "for example".
Re:GitHub Copilot as open source code laundering? by dwheeler on Friday July 02, 2021 @05:17PM (#27716997)
You certainly did! But there are a lot of people who think "OSS license means there are no requirements" and think it's okay to do things like copy without attribution when the license requires attributions. I know you didn't say anything like that either, but some others might think it.

It seems to me an important question is, "is this like a human who learns from examples, or is this really a derivative work in the copyright sense?".I'm not sure how to answer that. I'm not a lawyer. I don't know if many lawyers can answer that question either!

Re:GitHub Copilot as open source code laundering? by BlueTemplar on Sunday July 04, 2021 @11:04AM (#27730170)
Neither :

https://scholarship.law.cornell.edu/facpub/1481/

Copilot isn't human and therefore what it does isn't a "work".

The usual issues still apply to users of Copilot - unwitting violations of license terms of the code it was trained on (like non-attribution) are still violations.

Re:GitHub Copilot as open source code laundering? by drran on Wednesday June 30, 2021 @12:07PM (#27690219)
I have a much simpler AI Copilot, called "cat", which spills verbatim code more frequently, but it's OK for me. Can I train it on M$ code?
Re:GitHub Copilot as open source code laundering? by BlueTemplar on Sunday July 04, 2021 @05:54PM (#27732932)
My cat only spills drinks and produces garbage when walking over the keyboard... :'(
Re:GitHub Copilot as open source code laundering? by devetec on Wednesday June 30, 2021 @02:22PM (#27691865)
You could say a human is laundering GPL code if they learned programming from looking at Github repositories. Would you, though? The type of model they use isn't retrieving, it's having learned the syntax and the solutions that are used, just like a human would.
Re:GitHub Copilot as open source code laundering? by thrwaeasddsaf on Wednesday June 30, 2021 @06:44PM (#27694382)
> You could say a human is laundering GPL code if they learned programming from looking at Github repositories.

I don't have photographic memory, so I largely don't memorize code. I learn general techniques, and memorize simple facts such as APIs. I can memorize some short snippets of code, but these probably aren't enough to be copyrightable anyway.

> The type of model they use isn't retrieving

How do we know? It think it's very likely that it is largely just retrieving code that it memoized, and doing minor adjustment to make the retrieved pieces fit the context. That wouldn't differ much from finding code that matches the problem (whether on SO or Github), copy pasting the interesting bits, and fixing it until it satisfies the constraints of the surrounding code. It's impressive that AI can do that, but it doesn't sound like it's producing code.

I think the alternative to retrieving would actually require a higher level understanding of the world, and the ability to reason from first principles; that would be much closer to AGI.

For example, if I want to implement a linked list, I'm not going to retrieve an implementation from memory (although given that linked lists are so simple, I probably could). I know what a linked list is and how it works, and therefore I can produce working code from scratch.. for any programming language, even ones for which no prior implementations exist. I doubt co-pilot has anything remotely as advanced as this ability. No, it fully reliant on just retrieving and reshaping a pieces of memoized code; it needs a large corpus of code to memoize before it can do anything at all.

I don't need a large corpus of examples to copy, because I use my ability to reason in conjunction with some memoized general techniques and common APIs in order to produce original code.