News for hackers. Stuff that matters.
Re:Coping with Copilot by cmrdporcupine on Saturday August 20, 2022 @12:54PM (#32533450)
I will try it at some point, but I have... feelings... about its abuse of open source licenses software as a learning set.

Also I work in Rust these days, and use CLion. Not sure if it would be much help in that environment.

Re:Coping with Copilot by wokwokwok on Saturday August 20, 2022 @08:23PM (#32536305)
It works fine in clion with rust.

The completions are often more “similar to stuff I’ve typed before” rather than “generate this working function”, and it’s not an order of magnitude improvement over just regular intellij completion.

…but I find it’s generally better.

Up to you if you consider it worth the cost of paying for it, and the macro completion is so-so, but “its rust so copilot can’t do it” isn’t really true.

Re:Coping with Copilot by scoot on Saturday August 20, 2022 @01:34PM (#32533746)
I guess any "abuse" is the fact that any code reproduced verbatim doesn't carry the license under which it was originally published. But the reality is that what Copilot is most useful for is (semi) intelligent autocomplete, and generating functions that almost certainly exist as StackOverflow answers. It won't do any thinking for you when it comes to the bigger picture.
Re:Coping with Copilot by bayindirh on Saturday August 20, 2022 @01:03PM (#32533531)
I left GitHub on the spot, and moved to Source Hut the day Copilot released.
Re:Coping with Copilot by MichaelMoser123 on Saturday August 20, 2022 @02:05PM (#32533982)
someone can still mirror your stuff on github. I wonder if they should make a special open source license, that disallows use of the source code for the purpose of training something like Copilot.
Re:Coping with Copilot by dragonwriter on Saturday August 20, 2022 @02:07PM (#32533999)
> I wonder if they should make a special open source license, that disallows use of the source code for the purpose of training something like Copilot.

Since Microsoft uses material for copilot outside of licensing on the basis that it is Fair Use, that would probably have no effect in practice on whether or not the material is used in training something like Copilot. For that to matter, you’d first have to win a lawsuit on the basis that training something like Copilot requires permission of the copyright owner of the training material, to invalidate the premise of Microsoft’s action.

Re:Coping with Copilot by cmrdporcupine on Saturday August 20, 2022 @04:46PM (#32535030)
I don't care about all the handwaving here, it comes down to this.

The moment a fragment of code from a GPL'd or AGPL'd project shows up almost verbatim in someone's closed source or non-copylefted, etc. project, and someone proves it, sparks are going to fly.

And it's probably already happening, just people haven't discovered it yet.

How many years did the Oracle/Google lawsuit go on for? And in the end about a handful of a lines of code only tangentially related to the issue at hand?

Part of the lesson from that must be: employers should be telling their workers to say TF away from Copilot or things like it. And be careful in general when browsing source. License literacy is critical.

I don't touch it because I need to feed my kids. I don't need my career exploded. Overcautious? Maybe. I'll let someone else find out. I make a living in and around open source software.

Re:Coping with Copilot by bayindirh on Saturday August 20, 2022 @05:12PM (#32535177)
> The moment a fragment of code from a GPL'd or AGPL'd project shows up almost verbatim in someone's closed source or non-copylefted, etc. project, and someone proves it, sparks are going to fly.

I'm hoarding popcorn and can't wait for that, honestly.

> License literacy is critical.

It's beyond critical, but most people I have talked says that they see the right to copy and use any code they see online. They don't care.

Building this open source corpus was not easy, and we need to defend it too. This is a culture.

Re:Coping with Copilot by pabs3 on Sunday August 21, 2022 @01:12AM (#32537574)
Didn't it already happen that it spat out a function from Quake? And they then dealt with that by banning the particular function.

ISTR that Amazon's version of copilot has licensing info output too.

Re:Coping with Copilot by MichaelMoser123 on Saturday August 20, 2022 @02:52PM (#32534316)
> Since Microsoft uses material for copilot outside of licensing on the basis that it is Fair Use, that would probably have no effect in practice

i think that any formal violation of an open source license would be very bad in terms of public relations - even if they can claim fair use.

Re:Coping with Copilot by shagie on Saturday August 20, 2022 @11:48PM (#32537246)
Of note, a non-human cannot hold a copyright.

Anything generated by copilot, which if it is a derivative work, is not something that copilot can hold the copyright on.

From the auditor's perspective it doesn't matter if you copied it out of stack overflow, from some GitHub search, or copilot. You, the human, didn't check the license / plagiarism detecter. It is you, the human, claiming copyright on the work you are creating which may incorporate material from other sources.

Copilot isn't claiming fair use.

You could argue that the model that copilot runs from is a derivative work (and this is going to be interesting when it gets to the courts, because, frankly no one will come out the 'winner' on this when trying to explain it to a judge) - but that's not the code that a human is claiming to be their creative work and is ultimately the license violation.

Personally, I (not a lawyer), believe that copilot is on ok ground - but anyone using it needs to do their due diligence in verifying that the code that they've incorporated is licensed appropriately - just as if they've copied something from Stack Overflow - who knows where that copied was copied from.

I have less concerns with identifiable code from copilot than humans not caring about the licenses of their source material in creating human generated content.

Re:Coping with Copilot by bayindirh on Saturday August 20, 2022 @03:50PM (#32534697)
They got it covered. Passed the responsibility to user in their official documentation.
Re:Coping with Copilot by int_19h on Sunday August 21, 2022 @08:24AM (#32539467)
It's not really an issue when you're a large software corporation; you already have mechanisms in place to check for license compliance in everything that ships, including F/OSS plagiarism checks.

I think that's the part that people who don't think it's worth the money aren't getting. This kind of system is godsend for the likes of Infosys, TCS etc. So the immediate threat is to the jobs there - but the side effect is that it'll make it all even cheaper, so we'll see more "outsourcing to the cloud", so to speak. Often to the obvious detriment of quality, but that doesn't seem to matter in this market.

Re:Coping with Copilot by bayindirh on Saturday August 20, 2022 @03:51PM (#32534711)
> Someone can still mirror your stuff on github.

It is the nature of the beast, however I make my stance clear and stand by my principles. It is equally important for me.

Re:Coping with Copilot by gopher_space on Saturday August 20, 2022 @03:44PM (#32534654)
If it's your creation you can make your own license. Copy and paste a license you like and add a few lines.

This fact solves many "we need this lib but it's too open" problems. The author can make a special license just for you if they want.

Re:Coping with Copilot by bayindirh on Saturday August 20, 2022 @06:03PM (#32535550)
Re:Coping with Copilot by sidlls on Saturday August 20, 2022 @02:31PM (#32534167)
How is it abusive?
Re:Coping with Copilot by Gigachad on Saturday August 20, 2022 @07:19PM (#32536010)
There is a common trend of devs on HN getting angry that their work has been "stolen" to train copilot, While none of them raised the same concerns when everything else like art, music, literature, etc was used to train other models. Now that it affects them its a real issue.
Re:Coping with Copilot by sidlls on Saturday August 20, 2022 @09:58PM (#32536734)
Yes. It's especially amusing given that much of the other things you note are actually intended for commercial use (i.e. sales) from the start, unlike open source software.

I just don't understand the OSS community sometimes. "Software should be open and free (libre) for me to study and modify" includes what Github did for copilot. If you don't want your software to be free (in either sense), don't host it on an open source platform, especially one that makes it available gratis to the public.

There's possibly a valid argument that any private repo code that was used for copilot doesn't fit the proper definition of "open" (or gratis). But I haven't actually read the Github license around this, so I don't know.

Re:Coping with Copilot by cmrdporcupine on Saturday August 20, 2022 @10:44PM (#32536968)
Your argument fails to distinguish between "open source" and "free software".

Copyleft, free software, GPL style licenses do not have their source open purely for the purpose of studying and modifying. Their licenses also require that derivative works also be free and that such modifications be distributed.

Copilot does not comply with this. And so violates the spirit of those licenses, and probably also the letter of the law.

Re:Coping with Copilot by Gigachad on Sunday August 21, 2022 @12:02AM (#32537301)
Open source is usually referring to the OSI definition which is essentially identical to the FSF “free software” term.

And by that logic, gpt3 and dall-e are also copyright violations. Except this has never been proven to be the case.

Re:Coping with Copilot by sidlls on Sunday August 21, 2022 @12:00AM (#32537297)
I literally use “libre” and “gratis” to make that precise distinction.

And it’s at best questionable whether copilot is derivative of the code it is trained on.

Re:Coping with Copilot by xigoi on Monday August 22, 2022 @06:10AM (#32549456)
It's not about the distinction between “libre” and “gratis”, but about the distinction between copyleft and permissive.
Re:Coping with Copilot by WalterBright on Saturday August 20, 2022 @10:29PM (#32536891)
All the software I write is Open Source, and I'm happy to have anyone use it for any purpose.
Re:Coping with Copilot by Guest42 on Saturday August 20, 2022 @02:51PM (#32534314)
It was trained using source code whose licenses don't permit such usage.
Re:Coping with Copilot by sidlls on Saturday August 20, 2022 @04:39PM (#32534999)
In what sense? Copilot isn’t a derivative work in the sense these licenses usually are understood to mean. And given that they’re open source code bases I expect licenses to explicitly disallow things, and consider anything not explicitly disallowed as permitted.
Re:Coping with Copilot by teddyh on Saturday August 20, 2022 @06:51PM (#32535862)
> Copilot isn’t a derivative work in the sense these licenses usually are understood to mean

The phrase “derived work” is, IIUC, a phrase from copyright law. And you’d have a hard time convincing me that Copilot-generated code is not a derived work from its training data.

> And given that they’re open source code bases I expect licenses to explicitly disallow things, and consider anything not explicitly disallowed as permitted.

That is very much not how copyright and licences work. Copyright law gives the copyright holder the exclusive right to make copies of the work, making derived works, (and to do some other related things, like making a public performance of it, etc.), so to do any of those things, you need explicit permission, i.e. a license from the copyright holder to do it. A license is not a list of things you are forbidden to do; on the contrary, it is a list of things you are permitted to do, which you would not otherwise be legally allowed to do according to copyright law.

Re:Coping with Copilot by skybrian on Saturday August 20, 2022 @07:15PM (#32535980)
Sure, but there are things you can do without a license because they're not copyright violations. You can read the work, learn from it, and sometimes make quotations under fair use.

This is a novel scenario. It seems unclear how the courts will interpret it? Never mind what we think, will they decide it's a derivative work, or is it a transformative use?

https://en.m.wikipedia.org/wiki/Transformative_use

Re:Coping with Copilot by teddyh on Saturday August 20, 2022 @07:25PM (#32536036)
“Fair use” is, technically, not actually permitted by copyright law. ISTR that “fair use” is only a defense you can use when you are being sued for copyright violation.

Suppose we create a new AI image generator, and use as training input every image ever made of a Disney character (official images by Disney, that is, no fan art), including every frame of every Disney movie. Could we just use the output images of that AI however we wanted to? (Not withstanding trademarks.)

Re:Coping with Copilot by skybrian on Saturday August 20, 2022 @08:06PM (#32536240)
Looks like there is case law that fictional characters are protected if they are "sufficiently delineated." I don't see how that applies to code, though.

https://en.m.wikipedia.org/wiki/Copyright_protection_for_fic...

Re:Coping with Copilot by teddyh on Saturday August 20, 2022 @08:14PM (#32536271)
I guess we’ll find out.
Re:Coping with Copilot by skybrian on Saturday August 20, 2022 @04:13PM (#32534847)
This is unclear. I have never seen an open source license that was explicit about this. Seems like a grey area.

It's not even clear how often training machine learning algorithms on code results in copyright violations. CoPilot does have a setting to detect and disallow direct copying, but how well does it work?

This legal uncertainty is enough that I wouldn't advise using it, but maybe people who use it will be fine?

Re:Coping with Copilot by int_19h on Sunday August 21, 2022 @08:28AM (#32539490)
It's messy enough it's likely to end up a Supreme Court case in US (and I wouldn't want to be a party to it).

Europeans will probably preempt that with legislation.