This seems to completely ignore the fact that we've seen Copilot regurgitating exact copies of existing code, and even with the incorrect license attached when it was asked for it. [0]
It also has no relevance for the discussion at hand. Yes, Github can display all of its content – that's kind of the point of it.
But Copilot doesn't exist to show you random code snippets for the sole purpose of showing them.
Using this copyrighted material to create derivative works is a completely different use case, and not covered at all by the Google Books ruling, or any other I'm aware of.
What about Google Books Ngram Viewer? Isn't that a derivative work based on copyrighted content? It's more than just a search or preview - it contains both novel information and snippets of existing content. Is linguistic corpus a special case?
The research value actually turned activity that would be infringing into activity that was not infringing. Take away things like the ngram viewer and Google Books infringes.
Agree. I've written a comment on her blog about this. Hoping she'll enable it. I've published an opinion piece on the subject matter myself: https://rugpullindex.com/blog#BuiltonStolenData
That function exists in hundreds, if not thousands, of GitHub repositories. The function is so well known it has it's own Wikipedia page. If there is a more famous function in computer science, I don't know what it is. The fact that a machine trained on GitHub repositories might reproduce such common code is not alarming or surprising to me. I think people are using this as an example and implying it's happening all over the place, but I've yet to see another example like it.
Yes and you did no further research on your own since GitHub already said it's going to fix that (and a competent engineer would know it's trivial to fix that as well).
> On the other hand, the argument that the outputs of GitHub Copilot are derivative works of the training data is based on the assumption that a machine can produce works. This assumption is wrong and counterproductive. Copyright law has only ever applied to intellectual creations – where there is no creator, there is no work. This means that machine-generated code like that of GitHub Copilot is not a work under copyright law at all, so it is not a derivative work either. The output of a machine simply does not qualify for copyright protection – it is in the public domain. That is good news for the open movement and not something that needs fixing.
This is very good news. This line of thought implies that we can legally feed all proprietary code into GitHub Copilot in order to teach it all the patented and secret tricks of the companies we can see (since data mining is not copyright infrigement) in order to have it print those secrets back when we ask it to (so they become public domain).
"Patented and secret tricks" are not protected by copyright, if the output was an actual reimplementation of an idea instead of Copilot regurgitating existing code (https://news.ycombinator.com/item?id=27710287).
The specific implementations are protected by copyright, and the ideas may be protected by patents. In the case of "secret" tricks, they may be protected by trade secret laws, but not if it's in a public GitHub repo.
> The output of a machine simply does not qualify for copyright protection
Good, does the `cp` or `cat` command qualify for the "output of a machine"? Now I can uncopyright everything, hooray. What about converting a video or an image to another format? Again, it's just output of a machine.
Added:
Really, I would've been happy if this was the situation, as I'm, in general, against patents and copyright (in the form that they are now being used).
Except Copilot itself is not open source, so your only way to feed that proprietary code into it would be to upload it to github, which would make you an infringer.
> your only way to feed that proprietary code into it would be to upload it to github, which would make you an infringer
Somebody has to do it. Someone ready to take one for the team (or better yet, already skilled in software piracy, so that it's not a big deal for them). Then, if this argument holds, everyone gets the result in public domain.
As I see it, the argument presented in this post essentially makes Copilot to be an universal copyright laundering machine. Not just for code, but for anything that can be represented digitally.
Obviously this won't stand. While I can see Github ending up protected from all liability, the only way for this to not kill copyright is for the users of Copilot to become at risk of copyright infringement. Which kills the whole value proposition of Copilot.
This seems like a good time to ask what the heck is the value proposition of a thing like this. Are people really going to use the output of this blindly? And if they're going to audit every line - is that really easier than just writing the code yourself? Honestly, at best it feels like a machine for introducing pernicious bugs that "look right" but are semantically wrong. (Which reminds me - were any of the Underhanded C Contest entries in the training data?)
That's a very good question. On the surface, the idea seems to be helping people write code faster - but as you observe, properly auditing generated code is more work than actually writing it from scratch.
Best I can think of in terms of real value delivered, is helping people with first drafts, breaking through the "staring at an empty page" problem. But even with this, I feel it's too risky compared to doing a StackOverflow search, where you can at least see some explanations, discussions, and other relevant context.
It's definitely an interesting vision demonstrator - despite not being quite there, it lets us see that a tool like this that actually worked well (in terms of generating correct, explainable, license-respecting code) would be very useful.
Assume GitHub designs a filter to detect similarities to the training set and displays an attribution link with the result, as a comment. It's no different from using a search engine to find the code and putting it in your project, especially that the code is public already and visible to multiple search engines. You are ultimately responsible, just like you are every day with Google.
But the model has on average just 1 regurgitation in 10 weeks per user, so you can just discard all of them.
Almost all the output of Copilot is not an exact copy of any code in the training set. You discard the 0.001% of generations that are similar to the training data and use the rest.
Can they afford it, though? The most important feature of DNN models is that they're orders of magnitude smaller and cheaper to run than training data; checking each output against the training set will make the model orders of magnitude more expensive to run.
> The GitHub Copilot collects activity from the user’s Visual Studio Code editor, tied to a timestamp, and metadata.
[...]
> This data will only be used by GitHub for:
[...]
> - Improving the underlying code generation models, e.g. by providing positive and negative examples (but always so that your private code is not used as input to suggest code for other users of GitHub Copilot)
I'm inclined to believe this. After all, why would they taint the training data with code from a random guy who is asking for help when they have more than a hundred thousand repos with 100+ stars?
Sure, perhaps they won't use it for training, but the fear is they would use it for corporate espionage, market research, etc. Compared to training, this would be both more useful and much easier to keep deniable / under wraps.
I've had previous employers that were highly concerned about far more innocuous data leaking to competitors, e.g. autocomplete search terms. This means that a Copilot installation at any company that competes (or might compete) with MS should be considered a security breach, IMO. Given Microsoft's presence in so many markets, in general I think it would be foolish to risk this at any company.
You're still sending your intellectual property to Microsoft and hoping that they do only what they say they do with it, and that whatever they do with it will never change.
From context, I thought you were suggesting the strategy "just type pirated proprietary code into the IDE and the Copilot plugin will automatically include it in the training data", since my earlier comment was about the difficulty of training Copilot on such code. I don't believe they won't abuse your work in other ways either.
> Copyright law has only ever applied to intellectual creations – where there is no creator, there is no work
This is, at best, an oversimplification. Code compiled from copyrighted source code is derived work inheriting that copyright according to long-established law. This is exactly why the legal issues around machine learning applied to copyrighted corpora have been contentious.
Wow, that's quite a strawman/bait-and-switch from the article; thanks for highlighting it.
If Copilot is just a machine -- a glorified typewriter -- then the machine's operator is responsible for its output.
Or does the author seriously want to claim that any code added via Copilot to a proprietary codebase would not be proprietary as well? If that were true, Copilot's userbase is going to be...limited.
So then we come full circle on infringement, if the operator is responsible for the code produced by co-pilot then the articles claim that is not infringement because it is machine created fails, as the operator is responsible
The argument in the article is that all code made by co-pilot is not infringement because there is no copyright attached. You seem to imply that the copyright of all code made by co-pilot is copyrighted by the operator of co-pilot thus would then fall under copyright law, and thus would/could be infringing
> On the other hand, the argument that the outputs of GitHub Copilot are derivative works of the training data is based on the assumption that a machine can produce works. This assumption is wrong and counterproductive. Copyright law has only ever applied to intellectual creations – where there is no creator, there is no work.
Cool. I'll just train my new AI on 20 different copies of the same Disney movie and have it generate a new movie. Checkmate, lawyers!
I’m not sure what the point is. That the argument of copying Disney movies is not a good analogy, or that courts will find plagiarism in software copyright cases involving Copilot?
The point is that Copilot is effectively doing the Disney movie thing, just with code, and yet this article argues this is all fine. As it is, the article turns Copilot into an universal copyright laundering machine.
> The court of law would probably have you unveil and tear apart your process and find that you were trying to plagiarize in a roundabout way.
This is the whole idea. Copilot is spitting out considerable chunks of code that is licensed under GPL and it will be up to GitHub to prove that Copilot is not trying to plagiarize this code in a roundabout way.
In the very least, Copilot should have separate data stores for different groups of licenses: public domain, attribution-only, copyleft, etc.. That would already make it much more usable than the current "here's some code, it came from I don't know where, don't ask me" that literally looks like black market deals except they are GitHub-branded.
> You do understand that's not how laws work in general, right?
The only reason the law doesn't work this way for Microsoft Copilot is because the copyright holders are individuals who do not have the capital or expertise to file suit.
If Microsoft instead released a video editor addon that was trained on Disney movies and which would sometimes insert scenes of _any_ Disney movie you can bet your ass we wouldn't be having the same discussion.
Comparing code to movies - in code even a single char difference can change the meaning of everything, in movies - you can skip whole scenes and still get the meaning. I don't think the two are compatible, they are judged by different standards.
Generally speaking - probably yes. That’s because the output would be (a) transformative and (b) not likely to affect the profitability of the original work (at least not directly).
Note: I’m not really trying to comment specifically about the code/movie examples - just the general notion that the more input there is (from different sources), the likelihood that the use will be considered “Fair Use” increases.
Do you think this Copilot is some sort of advanced AGI who just became a genius programmer? Almost every piece of code that it "generates" you will find it almost verbatim in one or several public repos.
If you ever tried AI Dungeon before it imploded, you'd agree GPT-3 is pretty impressive and is generally capable of coming up with original stuff. Obviously with a bias towards the kind of stuff that's in the training dataset, which is why you try to use a very broad dataset. But still original.
I don't think the judge will care how you arrived at the copyright violation, only that you did. But hey, I'd love to see that court case anyhow, maybe I'm wrong.
Julia Reda's analysis depends on the factual claim in this key passage:
> In a few cases, Copilot also reproduces short snippets from the training datasets, according to GitHub’s FAQ.
> This line of reasoning is dangerous in two respects: On the one hand, it suggests that even reproducing the smallest excerpts of protected works constitutes copyright infringement. This is not the case. Such use is only relevant under copyright law if the excerpt used is in turn original and unique enough to reach the threshold of originality.
That analysis may have been reasonable when the post was first written, but subsequent examples seem to show Copilot reproducing far more than the "smallest excerpts" of existing code. For example, the excerpt from the Quake source code[0] appears to easily meet the standard of originality.
I'm not sure either —which is why I said "may have been reasonable" instead of "was reasonable" :)
I can see an argument for doing your own research, but I can also see an argument for basing an analysis on what GitHub said in the FAQ — I'm honestly a bit surprised that Microsoft's lawyers let them say that with a product that can reproduce such large blocks of verbatim code.
Yep. Individuals in a FAANG don't have the ability to launch a product without review. Just drafting a press release for a new product involves Comms oversight and VP-level approval.
The example you linked to is talking about a 16 line function from the Quake source. The Quake source is 167,594 lines in total (counting the C code only). Does that really fail to meet the standard for "smallest excerpt"?
Not only that, but it is clearly someone going out of their way to make it do that. I’m not sure that that is a reasonable test of how the program typically behaves.
Yes, it is, because that means that the algorithm will produce that copyrighted code regardless of the intent of the person who makes it misbehave. People could both accidentally and "accidentally" make it reproduce copyrighted code. In the first case, it's unintentional. In the second, how could you prove it's intentional?
Because of this whole mess, I am actually adding clauses to FOSS licenses that I am writing, just to ensure that my copyright on my code is not infringed by code laundering.
Not necessarily. If you do it right, you've got a perfectly GPL-compatible license (because such laundering is, technically, a violation of the GPL… probably) – it's just a license that's more explicit about what's a license violation.
GPL explicitly forbids re-licensing under more restrictive terms.
So either the added terms are not more restrictive, which basically means they are unnecessary and have no real effect; or they are more restrictive, which is incompatible with the GPL.
You can't have things go both ways. It seems that your argument is "we're not adding restrictions, we're just saying what we think Copyright law / the GPL should actually be like." But unfortunately you can't "clarify" Copyright Law or "clarify" the GPL by adding terms. Ultimately courts decide that.
(Of course, if somehow your "clarification" happens to align with a court decision, then maybe it will work after all. But in theory your "clarification" is still not necessary and has no additional effect....)
> But in theory your "clarification" is still not necessary and has no additional effect....
Except your clarification will be interpreted by a court of law. “This license is compatible with the GPL and I can interpret the GPL in a way that lets me do something this license says I can't” is much less likely to stand than “well maybe the author thought the GPL said this, but it actually says my interpretation”.
This, of course, presumes that such a license is actually compatible with the GPL, something I'm getting less and less certain of over time. (What constitutes a compiled form? If a predictive model doesn't count – which it might not, since it outputs source code, very much unlike how compiled programs normally work – then my argument falls down. And many other things would also knock the argument down; I'm not confident enough that all my assumptions are right, or that they should be right.)
wizzwizz4 is correct. Also, I have explicit clauses saying that GPL/AGPL dominate.
But yes, my licenses may be incompatible (one-way) with permissive licenses. I say "one-way" because code with permissive licenses can still be used in code under my licenses, but maybe not necessarily the other way around.
That does not really ring true to me. AGPL broadens the scope of violations as well, and you cannot use AGPL code in GPL-only code bases without turning the end product AGPL (but you can use GPL-only code in AGPL code bases).
If you're just adding something along the lines of "copying passages extensive enough to reach originality is a violation of this license" then that's indeed already covered by the GPL, and there is really no need to add such a passage other than to be more explicit - and confuse people at least at first about why your license is not actually the GPL. So there isn't much of a point to do it in the first place, in my humble opinion.
If you add text that says something along the lines of "you may not use this code as training data", then you created an incompatible license, and your code cannot be used in GPL code bases, and even worse, since it restricts what you can do with the code more than the GPL, it might even mean you stop being reverse-compatible and may not use GPL'ed code yourself in your own custom-license code base.
The AGPL does not further restrict code uses, just broadens the scope of when you have to make available the code, so it's fine there. However, the original BSD license with the advertising clause is considered incompatible with the GPL.
I am not a lawyer, and these are just my quick layman concerns. I fully recognize you're entitled to use whatever license you find suitable for your code and I am absolutely not entitled to your code and work whatsoever.
But that said, I wouldn't touch your code if I saw a "potentially problematic" custom license, and I wouldn't consider contributing to your projects either.
Honestly, with this whole debacle, I am not going to be accepting outside contributions anyway.
I also understand the concern with a problematic license. However, I don't plan to make a specific exemption about machine learning, but rather tie up an ambiguity.
What I think I'll do is that the license will require that when the licensed source code is used, partially or fully, as an input to an algorithm, the license terms must be distributed with the output of that algorithm.
I don't think this is a violation of the GPL at all because the GPL requires you to distribute the license with the binary code of GPL'ed code, and such binary code is the output of an algorithm (the compiler) whose input was the source code.
But what it would do is put the onus on GitHub that, if they used my code in training that data, if they distributed the results (as they are doing), they must distribute my license terms as well and tell users that some of the results are under those terms.
> binary code is the output of an algorithm (the compiler) whose input was the source code.
Just because binary code is produced by the operation of an algorithm on source code doesn’t make all output produced any algorithm on that source code binary code. Otherwise checksums and hashes and prime numbers would be copyrighted.
You have a point, which is why the legal system would still require that a copy be substantial before they count it as infringing. I would argue that Copilot has already been shown to copy substantial portions, though.
> something along the lines of "you may not use this code as training data"
Would such a term be legally binding under present copyright law? Other than disallowing inclusion in a redistributed dataset specifically intended for training ML models, it's not clear to me that it would actually prevent such use if you already had a copy on hand for some other purpose. (Specifically, note that GitHub indeed already has a copy on hand for their authorized primary purpose of publicly distributing it.)
More generally, the manner in which copyright law applies to machine learning algorithms in general hasn't been worked out by either the courts or legislature yet. Hence the current article ...
To be clear, my suspicion is that this is so unlikely to happen unintentionally that it does not represent a real risk. If the issue is that I can force it to generate infringing output if I really want to, it is an argument against the Web browser too, since I could just as easily use the copyright-unsafe "copy" feature.
Whereas using the browser's copy feature requires the user to have intent to use it, getting Copilot to produce exact code does not. And proving that intent is not easy.
I think companies will see that such code can be exactly reproduced and decide to stay away from Copilot. I hope they do. In fact, I am less willing to take outside contributions for my own code, even for bug fixes, just because of the risk that that code came from Copilot.
That makes sense if you ignore the idea that such a thing would seem unlikely to happen without intent, which was the key thing in the post you’re replying to.
Unlikely stuff will always happen with enough use. There are billions of lines of code in the world. There will be enough copyright violations. Even on single multi-million line codebases, there will be violations.
The answer to your first question is for the courts to decide, unfortunately.
However, for my purposes, using a new license with particular terms would only be to make companies like GitHub pause and think before using my code as "training" to an "algorithm" like Copilot.
I'm not at all in favor of the "code laundering" (which is a brilliant term, thank you). But I don't understand how you expect a new license to help.
1. A license applied to source code is effective because of your copyright
2. The claim of Copilot's maintainers is that it bypasses copyright
Therefore, they will assert that they can ignore the new license saying "you may not launder my code" just as surely as they can ignore the previous license.
Second, you are correct that Copilot's maintainers claim that it bypasses copyright, but if it does while producing exact copies of code, then copyright is dead, and there are a lot of big companies out there with deep pockets that will ensure that doesn't happen.
They may claim that because their algorithm is a black box, that whatever it produces has no copyright, but my licenses will push back directly on that claim by saying that if source code under the license is used as all or part of the inputs to an algorithm, whether all of the source code or partially, then the license terms must be attached to the output. After all, that's what we do with GPL and binary code. The binary code is the output of an algorithm (the compiler) whose input was the source code.
I hope by tying it together like that, the terms can close the loophole they are claiming. But of course, I am going to get a lawyer to help me with those licenses.
I wish. I just want users to know what rights they have. Ultimately, I want my software to serve end users, not companies. If companies add value for users with my software, that's exactly what I want.
But stripping licenses away so that users can't know what rights they have with my code is not that.
> ... if source code under the license is used as all or part of the inputs to an algorithm, whether all of the source code or partially, then the license terms must be attached to the output.
You're not getting it. If Copilot isn't currently infringing copyright then adding such a clause won't matter. Such a clause would only hold weight when copyright applies. On the other hand, if copyright does apply, then you don't need such a clause because the activity is already a violation of the vast majority of licenses. (It even violates extremely permissive ones because it effectively strips out the license notice.)
The GPL works specifically because copyright applies to the usecase in question. It simply specifies various requirements that you must meet in order to license the code given that copyright applies.
In short, you can't just put a clause into a license saying, effectively, "and also, this license confers superpowers which make it so that my copyright applies in additional situations where it otherwise wouldn't!".
I argue that, even if training a dataset is fair use, distributing the result is copyright infringement. I would want my license to make that part clearer.
> even if training a dataset is fair use, distributing the result is copyright infringement
I would be inclined to agree that the current situation (ie reproducing training examples verbatim) violates copyright. On the other hand, I'm not so sure that a trained model does (or even should) be subject to the copyright of the inputs.
Of course I acknowledge that the latter view is controversial and also that such issues are so new that they haven't had a chance to be meaningfully addressed by either the courts or the legislature yet.
As an example of a similar situation, see (https://www.thiswaifudoesnotexist.net/) which was trained entirely on copyrighted artwork. Note that there are at least three distinct issues here - training the model, distributing the model itself, and distributing the output of the model.
> I would want my license to make that part clearer.
But again, GitHub's argument here is that the license is completely irrelevant because it doesn't apply in the first place. Thus they won't care one bit about any clarifications you make one way or the other.
You said that you're "not so sure that a trained model does (or even should) be subject to the copyright of the inputs."
You missed my point. I'm not saying that the model is subject to the copyright of the inputs; I'm saying that the model's outputs are, which is entirely different. We say that the output of a compiler is still subject to the copyright of the inputs, so why not this?
I misspoke. (Err mistyped?) I suspect there will often be a stronger case to be made for the model itself falling under copyright than what it outputs. It's up to the courts and the legislature in the end though, so who knows.
Anyway, by providing public access to this thing I infer GitHub to be taking the position that copyright doesn't apply to the output. (And I suspect they are wrong, in particular because of the verbatim code samples people have managed to coax out of it.)
I think the GP's "license" would still be effective, although it would not be "open source" per the OSI definition.
Imagine this simplified scenario first: if I published a source file publicly without any licensing or explanation except a standard copyright notice - "Copyright (C) 2021 MY NAME, all rights reserved", do you think a random person/company can take that code and integrate it into a commercial product?
I would argue not (in general). Copyrights law as it is, does not permit a user who has access to a copy to do whatever they want with that copy (esp. if it involves more copying). OSS licenses do give you much freedom as long as you don't modify it, and that's why we have impression that we can do whatever with publicized source code. However, if we think about other types of copyrighted work, say movies for example, streaming services can "rent" you a movie multiple times even though you've paid to download the content previously. What are you paying for the second time you rent? Another example - some photographers may allow you to freely browse their works, but they can still make you pay money if you want to use their photo in your commercial product.
So why wouldn't copyright restrict usage of source code in similar situations? The GP only needs to add a condition to the license to restrict how users can use it. It will no longer be OSS, but as long as it's his work, I don't see why in principle it shouldn't work.
(In practice, I don't think it will make much difference -- I think your argument is still somewhat compelling, and some people will probably take your position. Conservative corporate lawyers aimed at reducing legal risk would disagree, so it's basically a matter of how much legal risk one is ready to take. Also, for an author trying to do this, note that suing Microsoft in these cases would be expensive, since they will likely fight back given that they spent so much money trying to do this, and the outcome will be uncertain. If really tested in court, given the result of the Oracle v Google case, if the US Supreme Court is impressed by the social/economic benefits that Android brings, I'm pretty sure the justices will be even more impressed by this intelligent code generation thingy, and might just grant this thing a fair use.)
Your summary is generally correct, and I certainly agree with the other commenter's position on their work. But I think you're still missing the point. Copyright is the mechanism that allows you to prevent copying, but GitHub's claim is that copyright is irrelevant to Copilot's input.
I have a nice strong lock on my door. GitHub (asserts that it) can enter my home through the window.
Adding another deadbolt to the door does not help.
I don't think I missed that point. I'm trying to argue that copyright is relevant to Copilot's input if not allowed by an OSS license.
Maybe I'm missing something (just not the thing you said), but has Github made any legal claims so far? The original article is written by a politician in EU...
Even if you're a lawyer defending Github in this case, there's still a couple things that needs to be clarified before you can make the case: (maybe the info is out there but I'm too lazy to research)
- Is Github only using code/repos that are explicitly under OSS licenses? (because if that's the case, then the discussion might be justified in presuming OSS terms, and it may be the case that more restrictive non-OSS licenses would require a different analysis)
- As somebody pointed out in another thread, the Github terms of service agreement seems to grant Github additional rights when dealing with user uploaded content. Is that a legal basis for the use?
> I'm trying to argue that copyright is relevant to Copilot's input if not allowed by an OSS license.
And I tend to agree with you (and the other commenter) here. But GitHub doesn't.
> has Github made any legal claims so far?
I'm not sure how actively, but the CEO was here in the announcement thread the other day saying that they think the ingestion of the inputs is a "fair use". They also have some material defending the output side: https://docs.github.com/en/github/copilot/research-recitatio...
> Is Github only using code/repos that are explicitly under OSS licenses?
I don't think we know exactly what code they used as inputs, no.
Their argument defending the output side doesn't hold water, IMO. If Copilot produces exact copies verbatim, even some of the time, then as long as customers don't have access to the code used to generate the model, how can they be sure?
It's a matter of scale. With a big enough codebase, there will be copyright violations.
> I don't think I missed that point. I'm trying to argue that copyright is relevant to Copilot's input if not allowed by an OSS license.
The point (that they claim that) you are missing is that if "copyright is relevant to Copilot's input" then almost all existing OSS licenses already don't allow that.
The licenses that I am making implicitly acknowledge the argument that training an ML model is fair use.
However, GitHub said nothing about the output of the model being fair use. My license will say that the output of their model is under the same license as the input, which means they have restrictions if they want to distribute it (i.e., actually have people use Copilot).
I think this will work because it doesn't say that GitHub is wrong. Instead, it says that, even if GitHub is right, it doesn't matter.
It would also be very bad for GitHub to claim that the output of an algorithm can't be under the same license as the input because we feed licensed code to algorithms all the time and claim that their output is still under the same license. We call those algorithms "compilers" and the binary code they produce is still copyrighted and licensed.
> I think your argument is still somewhat compelling, and some people will probably take your position.
I didn't mean to take a side or argue a position here. I was just pointing out that licenses hold no legal power in the event that copyright itself doesn't apply.
> ... So why wouldn't copyright restrict usage of source code in similar situations?
I'm certainly not an expert here but I believe you are mistaken about the extent to which current copyright law (in the US) restricts such usage. I also don't think that the examples you bring up are as simple as you seem to be making out.
You are legally permitted to record broadcast shows for later viewing; you are not permitted to redistribute the recordings though. I assume (but am not certain) that rentals and streaming are the same. (That being said, bypassing DRM has been made its own crime. This effectively amounts to an end run around the rights otherwise granted to you by US copyright law. But then there are specific exceptions where bypassing DRM is permitted. I digress.)
You aren't legally permitted to mirror the contents of a website (such as the New York Times) without permission but you are allowed to access it since they make it publicly available. You are even permitted to save a copy for your own purposes when you access it; you are not permitted to redistribute that copy.
For an extreme example, consider the recent LinkedIn case. Unless I misunderstood it, the court deemed it acceptable to scrape any publicly available content. Certainly most such scraped content was never explicitly licensed for that though!
Even if the license for a piece of code was entirely proprietary, GitHub presumably acquired it through legal means (ie intentional upload). Once they have it in their possession, it's not at all clear to me that current copyright law in the US has anything to say about how they use it (short of redistribution). Of course, if their ToS promises that they won't use it for other purposes then they can't do that. But assuming they never promised you that in the first place ...
There's a traditional argument here about needing a license to legally incorporate the copyrighted work of another into your own.
One possible counter argument is that training a model on publicly available work is analogous to a person viewing that work. So long as the model never outputs any of the original inputs (or only exceedingly small fragments of them that would fall under fair use regardless) it's not clear that those outputs constitute derivatives at all (in the legal sense). Or they might. The courts haven't weighed in yet as far as I know. (Consider GPT-3 or This Waifu Does Not Exist for additional examples of the sort of ambiguity that's possible here.)
Of course, one possible counter to that is that the model itself is (in many cases) effectively a lossily compressed copy of the original input works. So perhaps redistribution of the model itself would be a violation of copyright. But even if that turns out to be the case, it's still not clear that the output of such a model would run afoul of copyright.
I argue that the output of an algorithm has the same copyright as the inputs to the algorithm, and that's because we use compilers (algorithms) to transform source code all the time already, and no one says that the binary code (outputs) is not copyrighted.
The trouble is there seems to be an entire continuum when it comes to degree of transformation.
The compiler produces more or less a direct (logical) translation so it's clearly some sort of derivative. We go from C to machine code but the output still "means" the same thing as the input. (More precisely, it's approximately a mathematically transformed subset of the original input. Lots of information is removed, things are reorganized, and a bit of extraneous information gets added in the process.)
For something notably more muddy than a compiler, consider This Waifu Does Not Exist. Any given output is (typically) nowhere near any particular input but you can often spot various strong resemblances.
Alternatively, the implementation of sketch-rnn (https://magenta.tensorflow.org/sketch-rnn-demo) is quite different - it outputs pen strokes instead of pixels. Still, the legal questions remain the same.
For a significantly muddier example, consider GPT-3. The outputs are (typically) not even remotely similar to anything that was input except in very broad strokes.
Where does Copilot fall along this continuum?
For even more confusion, consider running a New York Times article through Google Translate. Are you in the clear to publish that? I seriously doubt it.
But what about running it through an ML algorithm that (attempts to) produce a very brief summary of it? Many such implementations exist in the real world today. Their output is nothing like the input - should it still fall under the copyright of the original?
Finally, it's worth pointing out that for many of the above computerized tasks there are direct human equivalents. Art can be traced on a light table. A drawing can be produced that fuses the styles of two references. News articles can be manually translated or summarized.
Again, my intention here isn't to argue a particular side. I'm just trying to make it clear how complicated this stuff is and the fact that we don't have clear legal answers for most of it yet.
Tool that could be used to violate copyright := Gets prosecuted by MPAA and friends, legislation is passed to make use / development / distribution of such tools illegal
Bigcorp ships the ML equivalent of ALLCODE.tgz, but you actually gotta look in the no/dont/open/this/folder/gplviolations/quake.c folder := Is this adequate proof that copyright is being violated?
Since I do not work for the MPAA, I don't see why you expect me to answer for them. Half of the article's argument is that any argument you could use to shut down Copilot would also give a lot of power to such entities if it were accepted.
Honestly, I feel most people don't care about that. What they do care about, is the risk of Copilot making the user liable for copyright infringement. Even a possibility of it spewing out non-public-domain code should be considered a showstopper for any use of Copilot-generated code in a commercial project.
Can Copilot produce licensed code verbatim, in enough quantities to matter, with a license your business would be infringing? Yes. Can you easily tell by looking at the output? No. Could someone end up suing you over it? Maybe, if they cared enough to find out. Can you honestly tell your investors, or a company you seek to be acquired by, that nobody else can have valid copyright claim against your code? No.
> Can Copilot produce licensed code verbatim, in enough quantities to matter, with a license your business would be infringing? Yes. Can you easily tell by looking at the output? No. Could someone end up suing you over it? Maybe, if they cared enough to find out. Can you honestly tell your investors, or a company you seek to be acquired by, that nobody else can have valid copyright claim against your code? No.
Well aren't all your assertions exactly the point of contention?
Well, the "enough quantities to matter" part wasn't tested in courts yet, but I fail to see a way to rule for "No" here in a way that wouldn't gift us an universal way to turn any code into public domain, destroying source code licensing as a concept. Other than this part, the first two claims have already been demonstrated, and the rest follow from them.
But that is in fact the most fundamental question here. And I’m not fully sold on the idea either that this is going to happen in real-world usage or that a single function in a massive program constitutes a large enough portion to be infringing.
Quake's square root function wasn't the only, or the largest, example of code Copilot reproduces verbatim. Among others I've seen to date is someone generating a real "About" page with PII information of some random software developer.
How much code is enough to infringe is a tricky question, though. It's not only a function of size, but also of importance/uniqueness - and we know that Copilot doesn't understand these concepts.
> ... or that a single function in a massive program constitutes a large enough portion to be infringing.
As part of the sequences of rulings in Google vs Oracle, the 9-line rangeCheck function, in the entirety of the Android codebase, was found to be infringing.
That excerpt has its own Wikipedia page, of course it meets the threshold of originality. In any case, once you are discussing this, you have entered the area of fair use; that is an admission of copyright violation.
Fair use is not a violation of copyright but a specified (and since 1976 statutory) exception to it. You are clearly impugning the doctrine with your comment.
> appears to easily meet the standard of originality
It's an algorithm. In the olden days, you couldn't copyright an algorithm, even an original one. There's only so many ways you can express an algorithm; the best ways are using code. So is it the intention that rewriting in Python an algorithm previously expressed in C would be infringing? Suppose the algorithm is re-expressed in English?
Allowing copyrights on algorithms is tantamount to allowing copyrights on thought-processes.
In the US, copyright may include the choice of variable names, the organization of the code into modules and functions, and other aspects which where there are the creative choices that may be protected under copyright law.
> the court presented a three-step test to determine substantial similarity, abstraction-filtration-comparison. This process is based on other previously established copyright principles of merger, scenes a faire, and the public domain.[1] In this test, the court must first determine the allegedly infringed program's constituent structural parts. Then, the parts are filtered to extract any non-protected elements. Non-protected elements include: elements made for efficiency (i.e. elements with a limited number of ways it can be expressed and thus incidental to the idea), elements dictated by external factors (i.e. standard techniques), and design elements taken from the public domain. Any of these non-protected elements are thrown out and the remaining elements are compared with the allegedly infringing program's elements to determine substantial similarity.
Emphasis mine. This specifically highlights that your example ('only so many ways you can express an algorithm') is not protected under US copyright law.
The originality requirement only applies to other aspects of the generated code, which in this case would include the comments that Copilot generated, and which clearly are not required for the algorithm to work.
For thought police like you describe, look to patent law.
An algorithm is maths, you can't patent maths. Patent lawyers and business people have however somehow managed to convince courts/patent authorities that configurations of computer systems are patentable (or some similar argument), which then makes software patentable (IANAL but I think it's something like this).
Either way, the copyright of source code is separate from that. Copyright is for the text of a program (the source code), that might e.g. implement an algrithm. The algorithm itself cannot be patented or otherwise legally protected.
An algorithm is maths, but a lot of code isn't algorithmic. Algorithms provably halt, and most software doesn't halt, let alone provably. Operating systems, browsers, games, etc. are non-algorithmic. It's hard to claim that something like a browser is just math and therefore deserves no IP protections.
An algorithm is a reasoning procedure. A program (e.g. a browser) embodies many algorithms.
I've not come across your stipulation that for a thing to count as an algorithm it must provably halt, but I can go along with that. So I'd argue that in most cases, any function or subroutine provably terminates, even if the program embodying it is not supposed to terminate.
I also don't agree that an algorithm is "just maths". At least, not if you then pivot to saying that a browser isn't "just maths". Any operation performed by a computer is "just maths", because what a CPU does is basically arithmetic and branching.
I don't think it's a question of what does and doesn't "deserve" IP protection. The source code of a browser is clearly an original work, and entitled to protection. But the ideas and procedures it embodies are not "works", and copyright isn't supposed to apply to ideas and procedures.
I'm against the very idea of "intellectual property". It must have seemed a good idea at the time, but I think patents and copyrights have become monsters that inhibit, rather than encourage, innovation and creativity.
> I also don't agree that an algorithm is "just maths". At least, not if you then pivot to saying that a browser isn't "just maths".
Algorithms are distinguished by their proofs of correctness. This elevates them above simple procedures. The halting problems tells us that there is no automatic way to determine whether or not a program terminates. So when we find one, it's like discovering a mathematical law. The proof of an algorithm's correctness is expressed independently of any programming language or platform. What else could they be other than math?
Things like browsers, games, operating systems, e-mail clients, music players etc. are not treated this way. They are not formally specified. They are implemented in the context of a machine and an actual running environment. The source code of the program usually doubles as its specification. It's very different compared to an algorithm.
I agree IP as a concept is bad, but this is the way of the world at least for now. Given where we are, for me it makes sense to draw a line between algorithms and software in the context of copyright.
I'm afraid I still don't agree with you; algorithms existed (and were named) long before The Halting Problem was stated. This "proof of correctness" claim doesn't wash with me.
Can you cite? (Wikipedia's explanation of what an algorithm is doesn't mention that). I'm open to being corrected, but not baldly contradicted.
In mathematics and computer science, an algorithm is *a finite sequence* of well-defined, computer-implementable instructions, typically to solve a class of specific problems or to perform a computation.
"Finite sequence", meaning it terminates. The wiki citation (The Definitive Glossary of Higher Mathematical Jargon) provides a little more: "A finite series of well-defined, computer-implementable instructions to solve a specific set of computable problems. It takes a finite amount of initial input(s), processes them unambiguously at each operation, before returning its outputs within a finite amount of time." https://mathvault.ca/math-glossary/#algo
So they stipulate finite input and output and finite runtime. This is in contrast to something like a webserver or OS, which has a potentially unbounded number of inputs, and is expected to run effectively forever.
I mean think about it, what does an OS kernel look like in its most distilled form? It's essentially just an entry point to an infinite loop. Same as games, where they're called "event loops" in that domain.
The way I think about it is this: if computers and programming languages and software didn't exist, algorithms still would. I don't think you can say the same about e.q. Quake. Quake isn't a mathematical truth even though it uses them to work, kind of like how engineers use physics to build a bridge, but the bridge itself isn't physics.
Well, I don't consider an OS or a browser to be the implementation of an algorithm. It has to be possible to understand an algorithm, re-implement it, and so on. I'd say you have to be able to hold it in your head - like Eratosthenes' Sieve.
I don't see anything in the WP article about proofs of correctness. "Finite sequence" surely just means that the number of instructions isn't infinite? Come to think of it, that wording seems rather hand-wavey; I wonder if I can find citations to help me improve it.
> I don't see anything in the WP article about proofs of correctness. "Finite sequence" surely just means that the number of instructions isn't infinite?
Well how are you going to show that the algorithm terminates for all inputs without a proof of correctness?
Huh, that's interesting. While I'm hesitant to suggest that what the world needs is even more patents, this doesn't make immediate sense to me.
Let's say someone comes up with a new sorting algorithm, which completes in less cycles than was previously believed possible. Sure, it's math, but isn't that a new, creative expression? Don't we want to encourage them to publish their algorithm (one of the key purposes of patents—this way, anyone can use it after 20 years), as opposed to keeping it hidden from the world?
It makes more sense to me than most software patents (admittedly, a low bar to clear). And if the patent office is doing its job (big if), the patents should only be granted for algorithms which are sufficiently novel.
A new super-fast sorting algorithm (not just a few cycles, but something that actually changes the O-number) would obviously be a fantastic boon - I would want the inventor to benefit from his cleverness.
But nowadays I think patent law isn't the right way to do that; trade secrets should be enough. I don't think that what is disclosed to the public in patent applications is of enough value to justify a long monopoly. It's not necessarily a problem with the written law; patents are horrible because of the way courts apply them.
An algorithm is definitely subject for patent. Its very strange to read such a statement on the interwebs which were heavily affected by patented image compression algorithm.
Copyright is (and has been, since the earliest days) about protecting the creative expression of an idea.
You can't copyright an algorithm, but you certainly can copyright the expression of an algorithm in Python. You cannot copyright the words of the English language and their meanings, but Noah Webster absolutely did copyright his dictionary, which was a creative expression of their definitions (and lobbied for the first increase to US copyright law). Webster wasn't the "thought police" for trying to copyright people's understanding of words in English, because he didn't and couldn't copyright them; he copyrighted his expression of what words meant.
If you read the creative expression of an algorithm in Python and then re-express it in English, then sure, copyright protection doesn't extend to that re-expression. But Copilot isn't doing that, it's quite clearly reproducing parts of the original creative expression of an algorithm, not the algorithm itself.
Here's an easy way to demonstrate it: open up a source file in any language other than C and try to get Copilot to spit out an implementation of Quake's fast-inverse-square-root algorithm. You will very quickly discover that Copilot doesn't "know" the algorithm; it only "knows" the specific creative expression of it (comments included).
Please omit flamebait from your HN comments. It tends to produce flamewars, which are tedious and nasty. Your comment would be fine without the last two sentences.
The excerpt from Quake code is literally one of the most famous functions out there. There is no wonder that it was reproduced verbatim. The share of such code, according to Github is really small.
It would be quite straightforward to write an additional filter that would check the generated code against the training corpus to exclude exact copies.
Would it? What would the threshold be? Twenty lines copied verbatim? Ten lines copied verbatim? What about boiler plate like ten #include statements at the beginning of a file? Or licenses in comments? What if someone has a one-liner that's unique enough to be protected by copyright?
> The excerpt from Quake code is literally one of the most famous functions out there. There is no wonder that it was reproduced verbatim.
The question that brings is that this was found because it is so famous, but what if it is repeating Joe Schmoe's weekend library project, but we will never know because its not famous?
This doesn't stand on its own as a defense: perhaps the 10 inputs were legitimate copies of a single source. They could be forked repos that were properly following the original's license, for example.
Or 10 different GPL projects that legitimately share code that remains copyrighted and protected by the GPL. Or 10 obscure projects that illegitimately copied code but haven't been caught.
Clearly, "10 other people did it" is no defense at all.
It might not even be "10 other people". For projects which originated outside Github, it's common for multiple users to have independently uploaded copies of the project. There's probably at least 10 users who have pushed copies of the GCC codebase to Github, for example.
> at least 10 users who have pushed copies of the GCC codebase
That is "10 other people". (Although your point stands, since there doesn't (or at least shouldn't to the point of criminal espionage) be any strong impediment preventing one person from creating 10 different accounts.)
But the fact that it did that at all should be proof that Copilot is, in fact, copy and pasting rather than actually learning and producing new things using intelligence.
This is a code search engine with the ability to integrate search results into your language syntax and program structure. The database is just stored in the neural network.
It’s definitely an impressive and interesting project with useful applications, but it’s not an excuse to violate people’s rights.
This is all just computational statistics. Why in the world would you invoke ill-defined anthropocentric terminology like "intelligence"? Of course a statistics program isn't "using intelligence".
But it's also not exactly just a database. It contains contextual relationships as seen with things like GPT that are beyond what a typical database implementation would be capable of.
A common tech-bro fallacy. We understand exactly what is happening at the base level of a statistics package. We can point to the specific instructions it is undertaking. We haven't the slightest understanding of what "intelligence" is in the human sense, because it's wrapped up with totally mysterious and unsolved problems about the nature of thought and experience more generally.
The fallacy is the god-of-the-gaps "logic" of assuming there's some hand-wavey phenomenon that's qualitatively different from anything we currently understand, just because reality has so much complexity that we are far from reproducing it. You're assuming there's a soul and looking for it, even though you don't call it that.
Intelligence is mysterious in the same way chemical biology is mysterious (though perhaps to another degree of complexity)... It's not mysterious in the way people getting sick was mysterious before germ theory. There's no reason to think there's some crucial missing phenomenon without which we can't even reason about intelligence.
> But it's also not exactly just a database. It contains contextual relationships as seen with things like GPT that are beyond what a typical database implementation would be capable of.
You mean in the same way that google.com isn't "just a database"?
If Copilot isn't intelligent, then what makes it more special than a search engine? How is Copilot not just Limewire but for code?
I could understand the argument that, if Copilot really is intelligent or sentient or something like that, then what it is producing is as original as what a human can produce (although, humans still have to respect copyright laws). However, I haven't seen anyone even attempt to make a serious argument like that.
It can produce code snippets that were never seen by generating fragments from various sources and combining them in a new way. This makes it different from a search engine, which only returns existing items.
Is it producing code (by which I mean creating/inventing new code by itself), or is it just combining existing code? Because to me it seems like the latter is a more appropriate description.
* AI searches for code in its neural-net-encoded database using your search terms (ex: "fast inverse square root")
* AI parses and generates AST from the snippet it found
* AI parses and generates AST from your existing codebase
* AI merges the ASTs in a way that compiles (it inserts snippet at your cursor, renames variables/function/class names to match existing ones in your program, etc)
* AI converts AST back into source code
Is AI intelligently producing new code in that example? Because I don't think it is.
What would be an interesting test of whether it can actually generate code is if it were tasked with implementing a new algorithm that isn't in the training set at all, and could not possibly be implemented by simply merging existing code snippets together. Maybe by describing a detailed imaginary protocol that does nothing useful, but requires some complicated logic, abstract concepts, and math.
A person can implement an algorithm they've never seen before by applying critical thinking and creativity (and maybe domain knowledge). If an AI can't do that, then you cannot credibly say that it's writing original code, because the only thing it has ever read, and the only thing it will ever write, is other people's code.
That isn't even necessary. I've been exploring GPT-3 for a while and it is completely incapable of any reasoning. If you enter short unique logical sentences like "Bob had 5 apples, gave 2 to Mary, then ate the same amount. How many apples Bob has left?" No matter how many previous examples you give it (to be sure it gets the question), it gets it wrong. It is simply incapable of reasoning about what is going on.
> How do you differentiate between these two things?
That's a contrived example because none of those lines could be protected by copyright, patents, etc. A better example might be if you started selling a 30 minute movie that was just the first 15 minutes of Toy Story spliced together with the last 15 minutes of Shrek. I'm not a lawyer, but I'm pretty sure that would qualify as a derivative work, meaning you're potentially infringing on someone's rights (unless they've given you permission/a license).
And to be clear, none of these problems are new. People have been fighting over copyright and it's philosophy in court for a very long time. The only thing that's different here is that it seems some people think it's ok to ignore copyright if you use Copilot as a proxy for the infringement.
> As an aside, your understanding of how the model works here is completely wrong. Like, just absolutely fundamentally completely wrong.
Of course I don't, it's a neural network. You don't know either. That example I posted could be exactly what it's doing, or not even close.
(although for the record, I wasn't trying to explain how copilot works in that comment. It was a hypothetical "AI" for the sake of discussion, not that it matters. My point about it being copyright infringement is the same even if that hypothetical implementation is wrong)
> That's a contrived example because none of those lines could be protected by copyright, patents, etc.
Well no. The question I'm asking about, the philosophical distinction between "producing" or "combining" is a valid question no matter the copyrightability of anything. It's an interesting philosophical question even if we presume that copyright is bubkis.
> It was a hypothetical "AI" for the sake of discussion, not that it matters.
Ah, my mistake. I see that now.
> Of course I don't, it's a neural network. You don't know either.
I may not know how to make a lightbulb, but I do know hundreds of ways not to make one ;)
> Of course I don't, it's a neural network. You don't know either. That example I posted could be exactly what it's doing, or not even close.
What is this supposed to mean? We know how neural networks generate things like this very very well.
I personally have built a system that takes pictures of hand drawn mobile app layouts into the NN, then generates a JSON based description file that I compile into a Reactive Native and/or HTML5 layout file.
This was trivially easy in 2018 when I did it. It took me maybe 2 weeks engineering time, and I'm no genius. Our understanding of how transformer-based NNs work has come a long way since then, but even back then it was easy to show how conditioning on different parts of the image would generate different code.
> A person can implement an algorithm they've never seen before by applying critical thinking and creativity (and maybe domain knowledge). If an AI can't do that, then you cannot credibly say that it's writing original code, because the only thing it has ever read, and the only thing it will ever write, is other people's code.
This doesn't hold at all. Not many people can come up with an original sorting algorithm for example, but people write code all the time.
But you seem to have a basic fundamental misunderstanding of what is going on inside the NN. There is no "search for code" - it is generating new code each time, but sometimes that code will be the same as something it has seen because there is little or no variation in the training data for that snippet.
The NN generates code token by token, conditioned on the code leading up to it (and perhaps the code ahead, similar to BERT).
If you see tokens like this you probably generate the same next token too:
for i in range(1,10)
You have conditioned your input on the code you have seen and the most likely token you produce is ":".
That's what the NN does, but for much longer range conditioning.
I am not educated on this matter, but I have to ask for your clarification. Would that not be just a pre-emptive lookup? Akin to keeping a cache of "results" per input token that are essentially memorized and regurgitated?
Sounds like there is still a db lookup, just not at runtime and instead at build time of the NN. Can you clarify this please?
GPT-3's raw output is "logits", or indexes into an encoding space. The encoding space contains individual tokens; for generation, it would be words, or even word pieces. The pieces are as small as "for", or "if". Constructing code from an embedding space, even if it is more specialized, is like constructing sentences by using a dictionary -- it is a lookup table, but it's not a database. Generation works by looking at the existing document (or portion), and based on what is already present, generating a token. Then repeating until some condition is met (such as length, end of sentence, something else).
The issue here is that certain sentences (code segments) are memorized, and reproduced -- much like a language learner who completes every sentence which begins with "Mi nombre" with the phrase "Mi nombre es Mark". The regurgitation is based on high probability built into the priors, not an explicit lookup. A different logit sampling method (instead of taking the likeliest) reduces regurgitation, without changing anything else about the network. (It also makes nonsense happen more often, since nonsense items are inherently less likely!)
The fact it reproduce code verbatim, including comments and even swear words means it is definitely copying some of the time.
Does it copy all the time? Doesn't matter. Plagiarism is plagiarism even regardless of it is done by a student in school, an author, a monkey or an "AI".
You wouldn't accept this from a student, you shouldn't accept it from a coworker (unless you are releasing under a compatible license) and of course you should accept it from Microsoft.
Perhaps it’s not so different from a search engine like Google. The article cites Google’s successful defence, under US copyright law, of its practice of displaying ‘snippets’ from copyrighted books in search results. There is a clear difference between this and the distribution of complete copies on LimeWire.
Co-pilot produces original code (as in code that has never been written before). It's not just combining snippets.
This should surprise no one who has seen the evolution of language models. Take a look at Kapathy's great write up from way back in 2015[1]. This generates Wikipedia syntax from a character-based RNN. It's operating on a per-character basis, and it doesn't have sufficient capacity to memorise large snippets. (The Paul Graham example spells this out: 1M characters in the dataset = 8M bits, and the network has 3.5M parameters).
Semantic arguments about "is this intelligence?" I'll let others fight.
That is can combine snippets doesn't mean the OP's understanding of how the system works is correct.
They seem to believe it is a database system. That's really not how this works, and the fact it behaves like one sometimes is disguising what it is doing.
If I say "write a "for" loop from 0 to 10 in Python" probably 50% of implementations by Python programmers will look exactly the same. Some will be retrieving that from memory, but many will be using a generative process that generates the same code, because they've seen and done similar things thousands of times before.
A neural network is doing a similar thing. "Write quicksort" makes it start generating tokens, and the loss function has optimised it to generate them in an order it has seen before.
It's probably seen a decent number of variations of quicksort, so you might get a mix of what it has seen before. For other pieces of code it has only seen one implementation, so it will generate something very similar. There could be local variations (eg, it sees lots of loops, so it might use a different variation) but in general it will be very similar.
But this isn't a database lookup function - it's generative against a loss function.
This is subtle distinction, but it is reasonable that people on HN understand this.
> Some will be retrieving that from memory, but many will be using a generative process that generates the same code, because they've seen and done similar things thousands of times before.
How are these not both the exact same process of memory recollection? Can you elaborate on the difference between memory recall vs a generative process based on conditioning? I understand how these two are different in application, but not understand why one would say they are fundamentally different processes.
Analogies start to break down once we are talking at this detailed level.
The best I can come up with is this:
Imagine you are implementing a system to give the correct answer to the addition of any two numbers between 1 and 100.
One way to implement it would be to build a large database, loaded with "x" and "y" and their sum. Then when you want to find out what 1 + 2 is you do a lookup.
The other method is to implement a "sum" function.
Both give the same results. The first process is a database lookup, the second is akin to a generative process because it's doing calculation to come up with correct result.
This analogy breaks down because a NN does have a token lookup as well. But the probabilistic computation is the major part of how a NN works, not the lookup part.
If you look at it this way, your brain is also "just" computational statics. (Or to be precise, it might be, since we don't yet know in all the details how it works).
Hint: it has been said hundreds of times since the advent of computer science that the brain is "just" [some simple thing that we already understand]. That notion has never once helped us in any way.
> actually learning and producing new things using intelligence
People have been trying to accomplish that for 65 years. We're not even close. It's the software equivalent of cold fusion (with less scientific rigor)
How do you know it's "just a code search engine"? Or "not AI" or "not learning and producing new things", or all the other claims people are making about it? All of these are essentially untestable statements.
It has memorized one thing. That doesn't prove it's not intelligent. If anything it's the other way around, we would expect an intelligent being to be capable of memorization.
All I can think of is the Turing test and the AI effect. Eventually we will have an AI that is capable of writing code indistinguishable from a human, and people will STILL say it's "not AI" and "just a code search engine", etc. Obviously this isn't there yet, but it's clearly getting closer.
I think it warrants investigating exactly how and when Copilot reproduces code, but using one example to write it off as just copy and pasting seems excessive.
Also when talking about rights, whether or not Copilot copies doesn't seem sufficient to make a call. For instance, if it has to be coerced by the programmer to produce these kinds of snippets in an obvious way, then it seems fine to lay the blame on the programmer similar to when using regular autocompletion (or copy+paste for that matter).
Pretty sure if someone trained a code suggestion tool with Windows source, Microsoft would claim that a single similar character being the same is grounds for copyright infringement.
They are putting GPL code in non-gpled codebases. Is it okay to take sections of other people's source code and use it on yours, if you just got it as a suggestion?
I would love to try a session of clean room reverse engineering using copilot. I would bet you get reasonably far for very common libraries with not much effort. The question would be if such compression/decompression would infringe copyright.
But that fast inverse square root example is particularly interesting because it is also a derivative work. Carmack did not invent it, and several variations of it had been passed around over time.
Algorithms should not be subject to copyright, that way lies madness. It would prevent new generations from building on top of the work of their predecessors, because copyright lasts a very long time. The amounts of code that github copilot reproduces fall squarely into the “shouldn’t be subject to copyright” domain for me, even if they pass the bar for originality.
Something which is a “derivative work” is still copyrighted. In fact, by definition, a “derivative work” is copyrightable. It’s the minimum threshold at which something, based on something else, gets its own, new copyright.
The algorithm is not copyrighted, but the source code of the function is copyrighted. You could learn how the algorithm works by reading the function, and then write your own function that implements the same algorithm. Algorithms are not copyrightable, they are not subject to copyright. Source code is copyrightable.
Copilot is not reproducing just the algorithm, it is spitting out large chunks of the copyrighted source code, verbatim.
The funny thing about the Quake function is, id Software is almost certainly not the origin of the code. They copied it from somewhere else, possibly added profane comments, then slapped GPLv2 on it. Did they even have the right to do that? From an IP absolutist standpoint, probably not.
It's not the actual copying of the idea, but the verbatim reproduction of the function, comments and all. I think people somehow thought that copilot could write code, and so verbatim reproduction was surprising to them.
A quick search shows that this snippet, including comments, is included in thousands of Github repos [1], so it's not surprising that the model learned to reproduce it verbatim.
It's such a famous snippet that it's even included in full on Wikipedia [2].
I wouldn't be surprised if the next version of Copilot filtered these out.
If you wrote an algorithm in the early 80s that did x+y+z
And then I saw your source code and in the late 80s I changed the variable names, function name, and logic to be x+y+z+0.1
And then I told my friend John that there's a super cool algorithm that adds numbers together, and he made some more changes to it and compiled it for a different platform...
Has anybody broken the law in your mind?
EDIT: because it would seem that the original authors (among them Cleve Moler) don't have any issue with what transpired
The GP's argument is that you don't have evidence that they didn't copy the whole function verbatim.
Is there a source that said they changed variable and function names and modified the logic?
> because it would seem that the original authors (among them Cleve Moler) don't have any issue with what transpired
Yet. Without an explicit license there is no basis to release it under the GPL (if the code was copied verbatim or had insufficient re-writing). What if the heirs of the copyright owner wanted to assert their rights? Is there a doctrine that if you don't assert your rights you lose them? (Presumably applies to trademarks, but I don't think this is the case for copyrights)
The source code in question is over 40 years old and most likely doesn't exist anymore in its original form.
What do we do then? The burden of proof for infringement is on original authors, and they haven't done so for 40 years.
In the late 1700s and early 1800s, Britain had to take measure to prevent visiting Americans and others from memorizing the designs of their new high tech machinery like the steam engine and the power loom.
Where do we draw the line? Shut down the internet until we create a massive copyright detection firewall?
No, we live with the copying and constantly evolve and adapt our business. Death to all patent trolls.
I won't even claim that people must necessarily follow the law. Copyright law is inconsistent at best, and notoriously hard to follow to the letter (and often ridiculous). In practice lawyers assess the legal risk and weigh the outcomes.
I never intended to discuss what we should do, and I definitely did not propose shutting down the internet...
The original discussion was such:
> > They did not copy the implementation, they copied the general idea of what the algorithm should do
> [Citation needed]
You said the original authors did not complain, which is neither here nor there, as I pointed out. There is still some theoretical legal risk if you copy with the owner's knowledge but not express consent. The fact that the burden of proof is on the authors is true but that they have not brought a claim does not mean they cannot prove infringement.
And in case I haven't made it clear, I don't think it's a bad idea to assume the function is under GPL, I just don't think there's a basis for claiming what you originally claimed, and there is still some level of (probably acceptable) risk if you take the purported license of source code as-is.
> > They did not copy the implementation, they copied the general idea of what the algorithm should do
> [Citation needed]
(Not really your point, as such, but) no, actually, if you claim they did something (nominally[0]) wrong, the onus is on you to provide citations showing they did it[1].
0: > From an IP absolutist standpoint
1: Well, or that they (voluntarily and explicitly) accepted some responsibility (such as a job as a police officer) that entails a higher level of scrutiny than innocent-until-proven-guilty, but that's not really relevant here.
> they copied the general idea of what the algorithms should do. Do not go down this line of reasoning
Too late, patents pick up where copyright ends, to protect general algorithmic ideas, not just implementations. And we have lots of patents on things that seem trivial now, including for-loops (just see how many patents depend on “a multiplicity”). Look - here’s a helpful lawyer’s template for including for-loops as a claim in your own patents: https://www.natlawreview.com/article/recursive-and-iterative...
> Anyone who believes in a free and open society should do away with all copyrights and patents.
Free and open sound good to me! What do they mean exactly? I guess it’s a non-debatable fact that copyrights and patents are abused by many big companies and patent trolls, but doing away with the system does seem extreme, it has also protected deserving individuals on occasion, no? You are saying that it should always be legal to copy someone else’s code / inventions without giving them any credit or compensation?
> Anyone who thinks that licensing will have an effect on what is happening in reality is severely misguided.
I’m not sure I understand what you mean; lots of licensing activity does have a measurable effect on reality. This article is only a small example, but people get sued all the time over taking code and using it without licensing it.
True, correct. I didn’t intend for my comment to be interpreted as suggesting that a claim in a patent is the same thing as a whole patent, I was just pointing out a fun fact.
The thing about the situation is that "copying code you found on the Internet" certainly isn't automatically, always legal. That you engaged in copying X from the Internet doesn't make illegal either. Your source for the source code your incorporate into a product doesn't matter, what matters is whether that code is copyrighted and what the license terms (if any) are (and people saying "copyright doesn't apply to machines" are wildly misinterpreting things imo).
Given what's come out, it seems plausible that you could coax the source of whatever smallish open source project you wished out of copilot. Claiming copyright on that code wouldn't be legal regardless of Copilot.
Whether Microsoft/Github would be liable is another question as far as I can tell. I mean, Youtube-dl can be used to violate copyright but it isn't liable for those violations. The only way Copilot is different from youtube-dl is that it tells it's users everything is OK and "they told me it was OK" is generally not a legal defense (IE, I don't know for sure but I'd be shocked if the app shielded it's users from liability). All the open source code is certainly "free to look at" and Copilot putting that on a programmers screen isn't doing more than letting the programmer look at it until the programmer does something (incorporating it into a released work they claim as their own would be act).
The question is how easily a programmer could accidentally come up with a large enough piece of a copyrighted work using Copilot. That question seems to be open.
TL;DR; My entirel amateur legal opinion is that Copilot can't violate copyright but that it's users certainly can.
I frankly think that the "free culture" label and extremely permissive licenses of many open source project are nothing but a redistribution of wealth upwards. Those with existing capital can make profitable unfree derivative works without any benefit to original authors. This relationship must go both ways if you want actual free culture. Stop producing MIT/BSD code in your non-work time.
This is not a research project, this is a commercial work that produces verbatim copies of code without disclosing its license (or having a license grant in many cases). It doesn't matter how it manages to reproduce it either. It does.
This is the closest anyone has ever come to convincing me to use GPL instead of MIT license.
But I still want to support small developers with anything I produce for fun, and I'm not willing to give that up to spite the big developers.
For instance, I wrote a small class to load OBJ files in Unity because I needed it for an idea. I went ahead and put it on Github for others that need it, too. I could easily see someone having an idea similar to mine that needed that and couldn't find it out there. (I think there are more libraries like that now, though.) I wanted them to feel comfortable using it, even if they eventually make money with their game.
If a big corp uses that code, too, that sucks. But there's no good way to draw that line in a license, so I didn't.
Having said that, in the future I could see releasing some software that I don't think anyone should profit from, and in that case I'd GPL it. Previously, I'd have just defaulted to the same MIT license. I'm just not sure what that'd be yet.
> This is the closest anyone has ever come to convincing me to use GPL instead of MIT license.
> But I still want to support small developers with anything I produce for fun, and I'm not willing to give that up to spite the big developers.
Another line of thought that may help you choose a license: Do not think only about other developers. Think about the final users of your code that will be running your algorithms on their computers. The GPL protects the right of these users to see and modify the code they run (your code). So-called permissive licenses, on the other hand, let middlemen to strip this right from your users.
Users of your code are in fact freer thanks to copyleft licenses.
> No, but it does force them to GPL their own code if they do. And that's a no-go for most companies.
There's many companies who release source code. I don't know enough to say if that makes the word "most" in your sentence false or not.
Anyways, a company using GPL code need not release all their own code. Just their modifications to that particular GPL program. And then again, only if they do intend to distribute the modified program.
> extremely permissive licenses of many open source project are nothing but a redistribution of wealth upwards
Although I license all my amateur work GPLv3, I dispute the assertion that more permissive licenses are "nothing but" a redistribution of wealth upwards.
Permissive licenses commoditize their features. This is of benefit to everyone, but organizations with more capital are better positioned to leverage that commodity, and typically when they do, they do so selfishly. This further centralizes value with them, but I believe this is still a better outcome than a closed license because of the educational/cultural/technical benefits to everyone of the open license. The capital leverage problem is orthogonal to that.
Copyleft licenses kind of do the same commoditization thing, but explicitly only for share-alike uses, which is why they're the only way to grow open culture relative to proprietary culture: they're designed to deny "freeloaders" on open culture by requiring all derivative works to also be open.
> without any benefit to original authors
Benefiting the original authors is not (directly) the point of open source.
MIT: "Here's some code, go nuts."
GPL: "Here's some code, go nuts, but share the nuts if you do."
There's zero value capture for the original author built into these licenses. If the original author wants to ensure they capture the value from their work, I recommend using a closed, proprietary license. Just be aware they're applying friction to the overall technological development of humanity by doing so.
I don't really expect any benefit when writing some pieces of code. These days I just make certain types of code I make public domain, because if it's MIT then BigCorp inc. will just make my name one in a really long list of contributors, and I won't get any benefit either.
I felt a great disturbance in the AI-community, as if millions of voices suddenly cried out in terror, of GPL Code in there output, and were suddenly silenced. I fear something terrible has happened.
Julia is one the few MEPs that properly engages with issues of copyright and is active in IT. I really appreciate it, even if I dont always agree with her
But she doesn’t seem to have engaged - she seems ignorant of basic facts of what the technology is doing in practice if you read the other comments here which give specific examples.
> Copyright law has only ever applied to intellectual creations – where there is no creator, there is no work. This means that machine-generated code like that of GitHub Copilot is not a work under copyright law at all, so it is not a derivative work either. The output of a machine simply does not qualify for copyright protection – it is in the public domain
This is fantastic news.
I'm going to create a bot that crawls sites like GitHub searching for popular libraries. Then it will copy them- sans any license- to it's own website where it will sell these libraries under a new name.
Since there is no creator here, just a piece of software, then there is no copyright violation. My system simply is "inspired" by the original source code using a proprietary algorithm that I call "Copy and paste".
I'm open to accepting venture capital for this project.
Id expect that since that’s your intention, as described above, then it is copyright and you would be the actor. In the GitHub case, it isn’t the primary intent but rather a byproduct of the goal of helping another developer? Not a lawyer, but spent enough time with lawyers to know that what you’re describing won’t fly. I don’t even know what GitHub is doing will fly, maybe they’re hoping it gets tested.
That looks to be as much about exceptions for education as about photocopying. Purely from a quick read of the Wikipedia article’s summary, it looks like a lot of it hinges on the interpretation of Section 52(1)(i), https://copyright.gov.in/Documents/CopyrightRules1957.pdf#pa..., “the reproduction of any work— (i) by a teacher or a pupil in the course of instruction; or (ii) as part of the question to be answered in an examination; or (iii) in answers to such questions”.
It's not news, it is fantastic, and you'd do well to understand it.
The output of copilot is macnine-generated and is not subject to copyright. Microsoft cannot claim copyright on what it generates. That does not affect my rights, or anyone else's. I can claim copyright on what I write, and neither copilot nor your stupidity diminish my rights.
MS may argue that what copilot copies is small enough that I have no copyright on that, and win in court. You may put forward the same argument but I think your fate in court would be different.
> The output of copilot is macnine-generated and is not subject to copyright. Microsoft cannot claim copyright on what it generates. That does not affect my rights, or anyone else's.
What about when I, a developer working on a proprietary codebase, blindly commit the output code into our product? Have I created a derivative work or, worse, plagiarized?
Right, which is why it feels like a bad-faith argument in this case to say "a machine can't produce copyrightable code, etc."
We aren't talking about a server sitting in a Microsoft data center shuffling code to another server without human intervention. We are talking about a tool that helps developers create code -- code that is "copyrightable and under another license", and thus in violation.
I think it's time for someone to train AI on leaked proprietary code and source-available code like Unreal Engine. It's cool that we have so much of it right now.
Then we'll see how fast Microsoft and others will shut it down.
If I understand what is being stated correctly; even if I assert a prohibition in my licence for my creative work (code) not to be used by Copilot (or any other machine learning model as training data), it wouldn't matter as its not covered by Copyright?
> The output of a machine simply does not qualify for copyright protection
"Simply"? If it were that simple, surely that would mean that the output of the Unix "cp" program would not qualify? What about a DVD copier?
I'm OK with copyright as it used to be, back when I was a teenager; the right expired with the author's life. Corporations couldn't own copyrights. There was no burden on the author to register their rights. And copyright was a civil matter; you sued for actual damages. Infringement wasn't a crime.
I'm not OK with modern copyright law, with criminal penalties, rights that can be transferred to entities that are essentially immortal, and copyright terms that keep getting extended, just before Mickey Mouse and Elvis Presley become public domain.
>> The output of a machine simply does not qualify for copyright protection
> "Simply"? If it were that simple, surely that would mean that the output of the Unix "cp" program would not qualify? What about a DVD copier?
It means that the output of "cp" does not qualify for copyright protection as a derivative work. The output is still a copy of the input and would be subject to the same copyright as that input.
Roughly, a derivative work is a new work that incorporates some copyrightable elements from a previous work. The derivative work gets its own copyright separate from the copyrights of those incorporated elements.
> Roughly, a derivative work is a new work that incorporates some copyrightable elements from a previous work.
By this logic:
- someone could go and copy functions and/or entire files from GPL code bases and use them with a different license.
- someone could use copilot or similar to learn from all available GPL code. Is resulting code GPL?
- someone could use copilot or similar to learn from open source code of their competitors that license doesn't allow them to use. Are the results legal?
The definition of a "derivative work" as stated is correct.
The copyright status of a derivative work is a separate issue: A derivative work can be considered infringing, and a derivative work can be considered non-infringing (ie. due to Fair Use).
Not necessarily. The object code produced by a compiler might best be regarded as a different form of the source code, even though it is not a copy or a new work, according to
> I think they meant “when the output of the machine is significantly original/transformed (i.e. is a new creative work).”
No; the author spends some time asserting that the output of a machine is inherently not a creative work:
> Machine-generated code is not a derivative work
> the argument that the outputs of GitHub Copilot are derivative works of the training data is based on the assumption that a machine can produce works. This assumption is wrong and counterproductive.
> This means that machine-generated code like that of GitHub Copilot is not a work under copyright law at all
The machine is performing some sort of transformation. Whether you want to call that a "(creative) work" or not is irrelevant to the point I was making: The machine is doing something to the input, and that makes the 'cp' comment I replied to kind of silly.
I think we can assume the author doesn't believe that piping bytes through the 'cp' command automatically removes copyright (as the person I replied to suggested).
> a legal expert weighs in [...] And HN rallies to criticize it
That is an appeal to authority. Being a legal expert does not excuse one's writing from critical analysis. In this case, the post does not address Copilot reproducing large segments of copyrighted code verbatim. That is valid criticism.
This discussion is heavily biased and prioritizes people's emotional need to be credited and/or paid for their work over a discussion of the legal and ethical concerns at play here. It disregards the comments of an expert in the field and focuses instead on demands that may well be unsupported by copyright law.
For example, GitHub license section D.4 specifically grants GitHub the right to display your content, analyze your content, and reproduce it in full to other users of the service. Yet no one seems particularly interested in discussing that here today, because it isn't compatible with the outrage that people are prioritizing on HN when discussion Copilot.
I would have expected HN to be better than Reddit in this regard, but I'm not seeing it yet. I don't know if the expert is right or wrong here, but nothing in today's comments suggests anything new or curious that hasn't already been ranted about in every prior thread about this topic. I specifically care about copyright law and it's disappointing to see HN having a group tantrum instead of a discussion.
The legal commentary I'm seeing from people who really know this stuff is pretty much unanimously in favor of this being legal in at least most of the world based on caselaw--while acknowledging why some might have ethical concerns.
I'm actually sort of curious as to the vigor of the backlash. Because Microsoft? Because of concerns about perceived further undermining of the GPL in particular? Because of people anxious to get their credit? Because...?
> I'm actually sort of curious as to the vigor of the backlash. Because Microsoft? Because of concerns about perceived further undermining of the GPL in particular? Because of people anxious to get their credit? Because...?
Because, this is really against the understanding of what was possible for copyrighted works. So, now that this is possible for anyone, copyright will start to get examined and hopefully updated to be useful in today's environment.
There are about a million problems with this.
This can even be used to intentionally launder source codes from a competitor. Apparently, all it will take will be to steal code (or just fork it), then create more than 10 copies on Github. At that point, copilot will start to emit the code during use. With all the legal commentary saying this isn't infringement, imagine how companies will be able to use this product.
Similarly, the training set can be intentionally polluted, so your competitor finds the output of Copilot worthless.
Because they’re not getting a share of GitHub’s future revenues from their works or from derivations or their work.
(Why do they care so much about revenue? Open source coders and ‘starving artists’, not to mention Covid economic wreckage, the US approach to medical insurance, and the total absence of Universal Basic Income in virtually all countries permitted to access GitHub.)
> For example, GitHub license section D.4 specifically grants GitHub the right to display your content, analyze your content, and reproduce it in full to other users of the service. Yet no one seems particularly interested in discussing that here today, because it isn't compatible with the outrage that people are prioritizing on HN when discussion Copilot.
Well, Copilot isn't really an analaysis and display of the source code within the original meaning that people held. That was meant more to run codeql, github actions, and other analysis while presenting the results in a repository to people. People never anticipated that github would strip their licenses from files and present their source code inside of VSCode for people to use freely. It may be legal, but what we are seeing now is an abuse of the sentences you just quoted that goes outside what they were originally understood to mean.
Is it fair use to remix two musical albums into a new derivative work, that cannot plausibly be judged to replace demand for either original work?
Is it fair use to autogenerate GIFs from movies, perhaps the most protected digital works on the Internet today, in order to use them as reaction memes on Imgur?
Is it fair use to autoextract code fragments from a code base, in order to use them as suggestions on GitHub?
The Internet, and I imagine HN, was in an uproar when the music industry attempted to kill the White Album, because it infringed on their freedom to remix and derive.
The Internet, and I imagine HN, was in an uproar when MLB attempted to kill unauthorized baseball GIFs and replace them with official curated ones, because it infringed on their freedom to remix and derive.
How, precisely, is remixing and deriving from code ‘abusive’, in contrast to the past ten or twenty years of pressure on the Internet to the contrary when remixing and deriving from music or movies?
This is a core point of the original post linked above, where the author is shocked by our demands for more prohibitive copyright interpretations, and I want to call this out more bluntly and less politely than they did:
Fair use of a work is almost always perceived as abusive and unfair by the creator of a work. Creators ignore the cognitive dissonance between their demand to have fair use rights granted more easily to the protected works of others, and their demand to have fair use rights granted less easily to their own protected works.
I see that dissonance go unaddressed in every top-level comment in today’s discussion. I see that desire to deny fair use rights driving hundreds of emotional me-too posts, without considering the framing of whether it is fair use in alignment with every prior copyright outrage we’ve discussed over the years.
My theory is that permitting discussion of fair use would weaken their efforts to groundswell a pitchfork mob, and no one wants to confront their own biases or emotional investment or inability to profit from their code.
Whatever the motivations, HN deserves better than this.
You wrote 11 paragraphs about how HN deserves better than what everyone except you wrote. Yet in your reply you didn't address the comment to which you replied.
If it helps you parse my reply, consider that fair use explicitly intends to allow unpredictable derivatives that might otherwise be rejected by the copyright owner of a work, and so most of my reply anchors directly to this final paragraph of yours:
> People never anticipated that github would strip their licenses from files and present their source code inside of VSCode for people to use freely.
I can’t offer you a more detailed mapping of my reply onto exclusively your talking points, as I didn’t consider that a viable constraint. My original point at top of thread remains clear on my mind as I try to provide - using the examples of my own questions and concerns, after objections in the past that I wasn’t! - of what better, more reasoned, more curious, more worthwhile conversation looks like on this topic.
I do accept that not everyone desires to see the change in tone I’m trying to represent here, and no doubt I have been imperfect in my efforts to represent it. I’m sad that this isn’t connecting for you, even though I accept each time I try this that understanding and agreement are never universal. Thank you for your effort in trying to understand all the same.
The Grey Album is the only example comparable to what Copilot is doing. And even this is tenuous. It was a one-off and even though the copyright holder EMI did not give permission, the creators of the content remixed were happy with the re-use. Moreover, Danger Mouse could have sought a statutory licence that only applies to music under US law, whereas no such thing exists for code.
None of the other examples match up because the GIFs are not being compiled into films. The remixed works are in a different field of endeavour.
If Copilot were being used to show snippets that scroll across the screen in hacker films, or used by musicians to rap a few lines of Rust code, that would be palatable to the copyright holders. It is transformative and very likely to be fair use.
If Danger Mouse, who created the Grey Album, had instead started a business selling access to a tool that splices in copyrighted music and video based on a clip that the user provided, facilitating widespread, systematic infringement, creators would have been far less sympathetic, and EMI far more persistent in their legal attempts shut it down and collect damages.
You ask a very insightful question. Let me see where I end up running out the analogy in a certain direction.
If Danger Mouse sold a remixing tool that enable widespread remixing of any/all albums, would DM be profiting illegally from the content of others?
In each individual case, the remix album produced would have to pass the fair use tests, and if the user produced a sufficiently close replica, they could be restrained from distributing it. But that wouldn’t implicitly be the remixing tool’s fault, unless it mechanically reproduced a complete protected work with the user completely unaware it was doing so. A dedicated user can make any tool produce a protected work, so we have to aim for the narrow window of user-oblivious in order to fault the tool.
Translating back to Copilot, this then becomes the question: can Copilot regurgitate an entire protected work for a user who then sells that work, with the user being fully unaware that they have reproduced a protected work without meeting fair use terms, such that Copilot is responsible?
Copilot requires user prompting to emit code, and seems to draw the line at around the single function boundary, so reproducing an entire codebase becomes exponentially less likely as the number of functions increases.
So if there were a weakness in Copilot’s defense, it would be in small single-function programs, at which point the parallel to another music case comes to mind: the person who generated and copyrighted every single musical phrase in Western major/minor, to prove that the law as written is not applicable when the total size and complexity of a given work falls below a certain threshold. I thus assume that Copilot is essentially protected in the single function case - it doesn’t matter if you have a protected work for (‘four’ (2 2 +) func), because that’s so simplistic that any human might reproduce it at any time unaided, and so claiming against them would fall flat when a judge applies the common sense threshold. It’s a high bar to expect a judge to recognize this analogy and understand code well enough, but I think between user intention to break fair use being required for complex multi-function systems, and the protection of snippets being essentially impossible to enforce against in music terms, would absolutely shield Copilot from being judged liable and owing damages.
(General disclaimer applies: I am not your lawyer, please seek legal counsel before making use of my opinion, etc.)
> For example, GitHub license section D.4 specifically grants GitHub the right to display your content, analyze your content, and reproduce it in full to other users of the service. Yet no one seems particularly interested in discussing that here today, because it isn't compatible with the outrage that people are prioritizing on HN when discussion Copilot.
How applicable is the Github license when a lot of code on Github (let's say eg. the Linux kernel) was posted there by people other than the individual copyright holders? I'd assume they can only rely on the open source license of the code in question, and not really on additional license terms. As far as I can tell, Github claims fair use rather than citing their license.
That's perhaps the most important question of this entire debate, and it's the one that no one is considering seriously here in the comments. I personally think that it's because no one at HN is both competent enough at copyright and licensing law to debate it and willing to spend time debating it with Internet commenters for a $0/hour wage.
If an oversight is all the excuse needed to dismiss considering anything I’ve said that you find unpalatable, then I can save you trouble and instruct you to dismiss everything I ever say, now and in the future, as I am merely human and will continue to be imperfect forever. I don’t generally intend to post this disclaimer on every comment I make, as this is a standard human condition defect in all of us, but I hope this one-time exception allows you to reject my opinions and move on to other discussions with a clear conscience.
> D.4 specifically grants GitHub the right to display your content, analyze your content, and reproduce it in full to other users of the service
If you read the section carefully, this covers the right of GitHub to do those things to your content "as necessary to provide the Service". "It also does not grant GitHub the right to otherwise distribute or use Your Content outside of our provision of the Service".
So, does "Service" only cover the type of Github's service at the time of the agreement, or does it allow Github to invent all kinds of unrelated services and use the code as such? If Github can provide a "Copilot" service that arguably "learns" the code, can it also provide a service that blatantly "copies" large pieces of source code for the user (without complying to OSS license terms)?
It's not very clear what the answer would be, but if what I described is allowed, the consequences of this term being so broad would imply that if you're not the copyright owner of code you uploaded to Github, you've probably violated some OSS license by agreeing to Github's terms.
Which OSS licenses are potentially incompatible with GitHub? Are they also incompatible with GitLab? How can one or the other be judged to have exceeded the bounds of what is permissible as a user-generated content provider, and/or fair use rights, in the legal jurisdiction of each?
Well, I have a hard time drawing a line between GitHub Copilot and a compression algorithm.
If you can reproduce a verbatim copy of Quake source code after taking that source code as input before then that's compression. A really fancy, but still.
And given that it reproduces the source code: it has to hold that somewhere.
It would be very interesting if someone could reproduce the Quake example with AGPL code, then request the whole model + code because it clearly contains the AGPL code in some encoded form.
Yes! In every form, lossy compression is distilling meaningful information from noise.
This is a great legal question as it concerns our use of machine agents. We can learn from copyrighted literature or code that we read. Why can't our agents?
Because the process is different. You and any computer agent are allowed to learn the functional, non-copyrightable elements of fast inverse sqrt. When you need that functionality, you can write code that implements your understanding of those non-copyrightable elements and gain copyright over the resulting creative expression.
What you can't do is copy all of the creative expression in the original (such as comments) without complying with the terms of the license. Moreover, reproducing the magic constants is a strong indication that your process didn't independently derive your code because the constants used in the original are unique and non-optimal.
> We can learn from copyrighted literature or code that we read.
Not everywhere. Emulators communities often prohibit people from contributing if they've read the original code to protect themselves from copyright claims.
If your model can't reproduce the Quake source without my input, you haven't really compressed it, especially if the dataset to recreate it is larger than the original. If I have to tell the program exactly what I want in detail to get the Quake source, that's more of a storage database. If I have to guide it intently to get it to output the Quake source, I'm heavily guiding it.
All decompression requires input: the compressed artifact. In this case, the compressed artifact is the semantic queues necessary to extract the Quake inverse square root function.
> especially if the dataset to recreate it is larger than the original
Many types of compression produce a compressed file larger than the original for input data that is not easily compressed. Just because a compressor is bad at compressing (some) inputs, doesn't exclude it from being a compression algorithm.
A compressed file containing Quake's source code would be covered by the copyright on Quake's source code. The compression algorithm would not. The algorithm cannot produce the plain-text copyrighted material without the compressed copyrighted material.
Copilot has the ability to produce Quake's source code nearly by itself. And it's a work (not a person), so it can be seen as a derived work. Like a compression algorithm that sometimes tacks on the first paragraph of "50 Shades of Grey" at the end of files.
I'm not a lawyer, but that's my opinion (admittedly, my opinion is softening each day). Plus, the purpose of the tool is to create code for inclusion in projects somebody will hold a copyright over, and they likely won't be the original authors. So it's output should be held to a higher standard than a compression algorithm or keyboard.
> Copilot has the ability to produce Quake's source code nearly by itself.
Was it fed the Quake source code while training? Then it's not producing that code, it's just reproducing it, like a fancy (but imperfect) copy machine.
I'm not sure it's accurate to say that the training source code is "compressed" in the parameters of the model, but certainly some approximation of the training source code is stored in the parameters.
It is probably a stretch, but I think less of a stretch than saying "it just a machine that learned to code and randomly reproduced these 10+ lines of code". That has IMHO a probability of 0.
So if I rule that out, where does it end up? What if we put this as the grown up ML brother of the chain of LZW, PPM, dictionary assisted compression (e.g. zstd) and various attempts at using neural networks for compression?
I would not want to judge this - that's why I put up the AGPL idea. Or even unlicensed code. It would be a very interesting case to watch.
> A compressed file containing Quake's source code would be covered by the copyright on Quake's source code. The compression algorithm would not.
What? Where does the distinction between data and algorithm go with compression algorithms?
In its most abstract form a compression algorithm is function `{0, 1}^n -> {0, 1}^m` such that n < m and the output string is the result of something previously encoded.
Why can't the input string be the seed used to make the machine learnt model generate the Quake source code?
I know absolutely nothing about IP and even less about compression but aren’t compression algorithms usually run on copyright protected material with the consent of the rights holder or authorized licensee?
You would not need to produce a perfect copy. A fansub of a movie is considered an derivative of the movie, while being a far cry from being an actually copy of the movie.
As a subtitle is to a movie, the quake "output" might be much smaller than quake itself.
Does anyone know which codebases got included? I get the impression copilot scraped github - but as it's an internal tool, did it only scrape public repos or has private repos also been slurped?
If they truly believe copilot does not produce derivative works, then there is no downside to indexing their own code in its entirety; it would probably improve copilot's behaviour.
Well, Microsoft, show us you believe your own arguments!
I've seen way too many screenshots of a dozen-line complete XHR wrappers being suggested[1] to complete a function to imagine Copilot as a generative machine. It's a somewhat fancy copy paste engine, with phenomenal search. But it's smuggled through enough complexity & machinery to obfuscate any legal obligations that might be attached to the original source material.
The article does not set itself up to address this at all:
> Since Copilot also uses the numerous GitHub repositories under copyleft licences such as the GPL as training material, some commentators accuse GitHub of copyright infringement, because Copilot itself is not released under a copyleft licence, but is to be offered as a paid service after a test phase.
I'm all for discussion of whether Copilot itself has to be copyleft. But to me, the immediate concern is that Copilot seems like a way to take copyleft works and remove the copyleft license from those works.
GPL does not permit you to copy source code without attribution. this copier does not provide attribution.
as i just said, i'm not so interested in debating the source-code-copier's licensing. i think it could go either way but i don't really care. the copied source code that the source code copier copies is interesting to me, and feel like the stochiastic parrot act bullshit they are pulling is massive massive sinfully evil bullshit without attribution. the stochiastic parrot can't just ignore all the licensing of what it parrots out.
But there's a Berne convention that kind of unifies copyright around the world, right? It's not like something can be copyrighted in one country but not another.
The Berne convention sets down some basic principles, but there are an awful lot of edge cases and it is very much the case that things can be copyrighted in one country but not another.
Heck, the duration of copyright isn't even uniform around the world.
Modern AI seems more like machine-assisted collage (or pictures, code, text, etc.) than anything else. Someone (of some other algorithm) needs to be added to ensure that the whole thing makes sense. The big problem here is that when an artist creates a collage he/she knows the sources. Here provenance is lost.
[1] Collage (/kəˈlɑːʒ/, from the French: coller, "to glue" or "to stick together";[1]) is a technique of art creation, primarily used in the visual arts, but in music too, by which art results from an assemblage of different forms, thus creating a new whole.
> What is astonishing about the current debate is that the calls for the broadest possible interpretation of copyright are now coming from within the Free Software community.
It is not astonishing at all given:
* proprietary codebase have not been indexed by copilot (at least a public version of it)
* arguably derived code will be used in proprietary programs
Yah, not sure what is astonishing about outrage in response to what appears to be a method for laundering GPL'd software.
Copilot ought only to have indexed public domain, wtf, and other wide-open licensed software. They should remove all GPL'd software from their model, even if that means retraining from scratch.
It's not just GPL, they arguably should remove MIT, BSD and most other Open Source software too, as it's hard to tell when any given snippet crosses a threshold where the original license demands attribution or other things. People seem to forget that even MIT license has actual conditions in it.
Of course derivative works are being produced!! Whether you blame Copilot or the developer using it, the result is something that required the original developer of the code in order to be constructed.
Have we reached the point where every “class X” must become “class X_GPL2_CopyrightJohnQSmith_AllRightsReserved” in every code base out there? Do we need to go from header comments at the top of a file to reminder comments at the end of every line?
This is kind of beside the point. Something can still be unethical and perfectly legal. The issue is that machine learning can whitewash a developers intended license.
Or put differently, as a GitHub customer, are you comfortable with your code being used this way? Instead of a passive host, your code is now being used to create tremendous value for GitHub and Microsoft. Do you feel your trust has been violated? (regardless of legality).
561 comments
[ 2.6 ms ] story [ 315 ms ] thread[0] https://twitter.com/mitsuhiko/status/1410886329924194309
But Copilot doesn't exist to show you random code snippets for the sole purpose of showing them.
Using this copyrighted material to create derivative works is a completely different use case, and not covered at all by the Google Books ruling, or any other I'm aware of.
Google isnt making new books, or enabling people to make derivative copies; it is merely previewing a book.
Github search is a preview. Copilot is a copy/paste.
https://books.google.com/ngrams
The research value actually turned activity that would be infringing into activity that was not infringing. Take away things like the ngram viewer and Google Books infringes.
Edit: My comment was enabled: https://juliareda.eu/2021/07/github-copilot-is-not-infringin...
Maybe fizzbuzz?
Let's try to auto generate some fizzbuzz code, see what we get :D
The article doesn’t seem to address this?
This is very good news. This line of thought implies that we can legally feed all proprietary code into GitHub Copilot in order to teach it all the patented and secret tricks of the companies we can see (since data mining is not copyright infrigement) in order to have it print those secrets back when we ask it to (so they become public domain).
/s
The specific implementations are protected by copyright, and the ideas may be protected by patents. In the case of "secret" tricks, they may be protected by trade secret laws, but not if it's in a public GitHub repo.
Good, does the `cp` or `cat` command qualify for the "output of a machine"? Now I can uncopyright everything, hooray. What about converting a video or an image to another format? Again, it's just output of a machine.
Added:
Really, I would've been happy if this was the situation, as I'm, in general, against patents and copyright (in the form that they are now being used).
Somebody has to do it. Someone ready to take one for the team (or better yet, already skilled in software piracy, so that it's not a big deal for them). Then, if this argument holds, everyone gets the result in public domain.
As I see it, the argument presented in this post essentially makes Copilot to be an universal copyright laundering machine. Not just for code, but for anything that can be represented digitally.
Obviously this won't stand. While I can see Github ending up protected from all liability, the only way for this to not kill copyright is for the users of Copilot to become at risk of copyright infringement. Which kills the whole value proposition of Copilot.
Best I can think of in terms of real value delivered, is helping people with first drafts, breaking through the "staring at an empty page" problem. But even with this, I feel it's too risky compared to doing a StackOverflow search, where you can at least see some explanations, discussions, and other relevant context.
It's definitely an interesting vision demonstrator - despite not being quite there, it lets us see that a tool like this that actually worked well (in terms of generating correct, explainable, license-respecting code) would be very useful.
But the model has on average just 1 regurgitation in 10 weeks per user, so you can just discard all of them.
> The GitHub Copilot collects activity from the user’s Visual Studio Code editor, tied to a timestamp, and metadata.
[...]
> This data will only be used by GitHub for:
[...]
> - Improving the underlying code generation models, e.g. by providing positive and negative examples (but always so that your private code is not used as input to suggest code for other users of GitHub Copilot)
I'm inclined to believe this. After all, why would they taint the training data with code from a random guy who is asking for help when they have more than a hundred thousand repos with 100+ stars?
[0] [https://docs.github.com/en/github/copilot/about-github-copil...]
I've had previous employers that were highly concerned about far more innocuous data leaking to competitors, e.g. autocomplete search terms. This means that a Copilot installation at any company that competes (or might compete) with MS should be considered a security breach, IMO. Given Microsoft's presence in so many markets, in general I think it would be foolish to risk this at any company.
And lines such as:
Secret tricks are usually a company secret, not really protected by copyright either.
NDAs and similar are also not copyrights.
Even trademark is not copyright.
This is, at best, an oversimplification. Code compiled from copyrighted source code is derived work inheriting that copyright according to long-established law. This is exactly why the legal issues around machine learning applied to copyrighted corpora have been contentious.
If Copilot is just a machine -- a glorified typewriter -- then the machine's operator is responsible for its output.
Or does the author seriously want to claim that any code added via Copilot to a proprietary codebase would not be proprietary as well? If that were true, Copilot's userbase is going to be...limited.
The argument in the article is that all code made by co-pilot is not infringement because there is no copyright attached. You seem to imply that the copyright of all code made by co-pilot is copyrighted by the operator of co-pilot thus would then fall under copyright law, and thus would/could be infringing
Right; I don't see how that's even remotely a tenable argument. I think the article is trying to eat its cake and have it too.
Cool. I'll just train my new AI on 20 different copies of the same Disney movie and have it generate a new movie. Checkmate, lawyers!
The court of law would probably have you unveil and tear apart your process and find that you were trying to plagiarize in a roundabout way.
Well, yes, that's the point.
This is the whole idea. Copilot is spitting out considerable chunks of code that is licensed under GPL and it will be up to GitHub to prove that Copilot is not trying to plagiarize this code in a roundabout way.
In the very least, Copilot should have separate data stores for different groups of licenses: public domain, attribution-only, copyleft, etc.. That would already make it much more usable than the current "here's some code, it came from I don't know where, don't ask me" that literally looks like black market deals except they are GitHub-branded.
One regurgitation in 10 weeks per user. Not considerable. Could be just skipped with a simple search by Github.
The only reason the law doesn't work this way for Microsoft Copilot is because the copyright holders are individuals who do not have the capital or expertise to file suit.
If Microsoft instead released a video editor addon that was trained on Disney movies and which would sometimes insert scenes of _any_ Disney movie you can bet your ass we wouldn't be having the same discussion.
So using machine learning with one movie is illegal, but using it with a million isn't?
Note: I’m not really trying to comment specifically about the code/movie examples - just the general notion that the more input there is (from different sources), the likelihood that the use will be considered “Fair Use” increases.
https://en.wikipedia.org/wiki/Fair_use
> In a few cases, Copilot also reproduces short snippets from the training datasets, according to GitHub’s FAQ.
> This line of reasoning is dangerous in two respects: On the one hand, it suggests that even reproducing the smallest excerpts of protected works constitutes copyright infringement. This is not the case. Such use is only relevant under copyright law if the excerpt used is in turn original and unique enough to reach the threshold of originality.
That analysis may have been reasonable when the post was first written, but subsequent examples seem to show Copilot reproducing far more than the "smallest excerpts" of existing code. For example, the excerpt from the Quake source code[0] appears to easily meet the standard of originality.
[0]: https://news.ycombinator.com/item?id=27710287
I can see an argument for doing your own research, but I can also see an argument for basing an analysis on what GitHub said in the FAQ — I'm honestly a bit surprised that Microsoft's lawyers let them say that with a product that can reproduce such large blocks of verbatim code.
So it could be that the executives really wanted to do it, and the lawyers thought "OK, technically we're not violating anything...."
That's not what people care about, people care about their copyright being blatantly violated by a massive corporation _without any consequences_.
Yes, it is, because that means that the algorithm will produce that copyrighted code regardless of the intent of the person who makes it misbehave. People could both accidentally and "accidentally" make it reproduce copyrighted code. In the first case, it's unintentional. In the second, how could you prove it's intentional?
Because of this whole mess, I am actually adding clauses to FOSS licenses that I am writing, just to ensure that my copyright on my code is not infringed by code laundering.
Doesn't this make your new licenses incompatible to a lot of existing licenses?
Law isn't code.
So either the added terms are not more restrictive, which basically means they are unnecessary and have no real effect; or they are more restrictive, which is incompatible with the GPL.
You can't have things go both ways. It seems that your argument is "we're not adding restrictions, we're just saying what we think Copyright law / the GPL should actually be like." But unfortunately you can't "clarify" Copyright Law or "clarify" the GPL by adding terms. Ultimately courts decide that.
(Of course, if somehow your "clarification" happens to align with a court decision, then maybe it will work after all. But in theory your "clarification" is still not necessary and has no additional effect....)
Except your clarification will be interpreted by a court of law. “This license is compatible with the GPL and I can interpret the GPL in a way that lets me do something this license says I can't” is much less likely to stand than “well maybe the author thought the GPL said this, but it actually says my interpretation”.
This, of course, presumes that such a license is actually compatible with the GPL, something I'm getting less and less certain of over time. (What constitutes a compiled form? If a predictive model doesn't count – which it might not, since it outputs source code, very much unlike how compiled programs normally work – then my argument falls down. And many other things would also knock the argument down; I'm not confident enough that all my assumptions are right, or that they should be right.)
But yes, my licenses may be incompatible (one-way) with permissive licenses. I say "one-way" because code with permissive licenses can still be used in code under my licenses, but maybe not necessarily the other way around.
I'm okay with that.
If you're just adding something along the lines of "copying passages extensive enough to reach originality is a violation of this license" then that's indeed already covered by the GPL, and there is really no need to add such a passage other than to be more explicit - and confuse people at least at first about why your license is not actually the GPL. So there isn't much of a point to do it in the first place, in my humble opinion.
If you add text that says something along the lines of "you may not use this code as training data", then you created an incompatible license, and your code cannot be used in GPL code bases, and even worse, since it restricts what you can do with the code more than the GPL, it might even mean you stop being reverse-compatible and may not use GPL'ed code yourself in your own custom-license code base.
The AGPL does not further restrict code uses, just broadens the scope of when you have to make available the code, so it's fine there. However, the original BSD license with the advertising clause is considered incompatible with the GPL.
I am not a lawyer, and these are just my quick layman concerns. I fully recognize you're entitled to use whatever license you find suitable for your code and I am absolutely not entitled to your code and work whatsoever.
But that said, I wouldn't touch your code if I saw a "potentially problematic" custom license, and I wouldn't consider contributing to your projects either.
Honestly, with this whole debacle, I am not going to be accepting outside contributions anyway.
I also understand the concern with a problematic license. However, I don't plan to make a specific exemption about machine learning, but rather tie up an ambiguity.
What I think I'll do is that the license will require that when the licensed source code is used, partially or fully, as an input to an algorithm, the license terms must be distributed with the output of that algorithm.
I don't think this is a violation of the GPL at all because the GPL requires you to distribute the license with the binary code of GPL'ed code, and such binary code is the output of an algorithm (the compiler) whose input was the source code.
But what it would do is put the onus on GitHub that, if they used my code in training that data, if they distributed the results (as they are doing), they must distribute my license terms as well and tell users that some of the results are under those terms.
Just because binary code is produced by the operation of an algorithm on source code doesn’t make all output produced any algorithm on that source code binary code. Otherwise checksums and hashes and prime numbers would be copyrighted.
Bats are not birds.
Would such a term be legally binding under present copyright law? Other than disallowing inclusion in a redistributed dataset specifically intended for training ML models, it's not clear to me that it would actually prevent such use if you already had a copy on hand for some other purpose. (Specifically, note that GitHub indeed already has a copy on hand for their authorized primary purpose of publicly distributing it.)
More generally, the manner in which copyright law applies to machine learning algorithms in general hasn't been worked out by either the courts or legislature yet. Hence the current article ...
Whereas using the browser's copy feature requires the user to have intent to use it, getting Copilot to produce exact code does not. And proving that intent is not easy.
I think companies will see that such code can be exactly reproduced and decide to stay away from Copilot. I hope they do. In fact, I am less willing to take outside contributions for my own code, even for bug fixes, just because of the risk that that code came from Copilot.
For example, a book could be copyrighted, but they certainly cannot sue me because a book i wrote contains a sentence that is the same.
However, for my purposes, using a new license with particular terms would only be to make companies like GitHub pause and think before using my code as "training" to an "algorithm" like Copilot.
1. A license applied to source code is effective because of your copyright
2. The claim of Copilot's maintainers is that it bypasses copyright
Therefore, they will assert that they can ignore the new license saying "you may not launder my code" just as surely as they can ignore the previous license.
Second, you are correct that Copilot's maintainers claim that it bypasses copyright, but if it does while producing exact copies of code, then copyright is dead, and there are a lot of big companies out there with deep pockets that will ensure that doesn't happen.
They may claim that because their algorithm is a black box, that whatever it produces has no copyright, but my licenses will push back directly on that claim by saying that if source code under the license is used as all or part of the inputs to an algorithm, whether all of the source code or partially, then the license terms must be attached to the output. After all, that's what we do with GPL and binary code. The binary code is the output of an algorithm (the compiler) whose input was the source code.
I hope by tying it together like that, the terms can close the loophole they are claiming. But of course, I am going to get a lawyer to help me with those licenses.
But stripping licenses away so that users can't know what rights they have with my code is not that.
You're not getting it. If Copilot isn't currently infringing copyright then adding such a clause won't matter. Such a clause would only hold weight when copyright applies. On the other hand, if copyright does apply, then you don't need such a clause because the activity is already a violation of the vast majority of licenses. (It even violates extremely permissive ones because it effectively strips out the license notice.)
The GPL works specifically because copyright applies to the usecase in question. It simply specifies various requirements that you must meet in order to license the code given that copyright applies.
In short, you can't just put a clause into a license saying, effectively, "and also, this license confers superpowers which make it so that my copyright applies in additional situations where it otherwise wouldn't!".
I argue that, even if training a dataset is fair use, distributing the result is copyright infringement. I would want my license to make that part clearer.
I would be inclined to agree that the current situation (ie reproducing training examples verbatim) violates copyright. On the other hand, I'm not so sure that a trained model does (or even should) be subject to the copyright of the inputs.
Of course I acknowledge that the latter view is controversial and also that such issues are so new that they haven't had a chance to be meaningfully addressed by either the courts or the legislature yet.
As an example of a similar situation, see (https://www.thiswaifudoesnotexist.net/) which was trained entirely on copyrighted artwork. Note that there are at least three distinct issues here - training the model, distributing the model itself, and distributing the output of the model.
> I would want my license to make that part clearer.
But again, GitHub's argument here is that the license is completely irrelevant because it doesn't apply in the first place. Thus they won't care one bit about any clarifications you make one way or the other.
You missed my point. I'm not saying that the model is subject to the copyright of the inputs; I'm saying that the model's outputs are, which is entirely different. We say that the output of a compiler is still subject to the copyright of the inputs, so why not this?
Anyway, by providing public access to this thing I infer GitHub to be taking the position that copyright doesn't apply to the output. (And I suspect they are wrong, in particular because of the verbatim code samples people have managed to coax out of it.)
That seems an unlikely legal argument. It would defeat the point of fair use if you couldn’t distribute the result.
And no copyright license can override copyright law. Licenses can only grant rights, they can’t take them away.
Imagine this simplified scenario first: if I published a source file publicly without any licensing or explanation except a standard copyright notice - "Copyright (C) 2021 MY NAME, all rights reserved", do you think a random person/company can take that code and integrate it into a commercial product?
I would argue not (in general). Copyrights law as it is, does not permit a user who has access to a copy to do whatever they want with that copy (esp. if it involves more copying). OSS licenses do give you much freedom as long as you don't modify it, and that's why we have impression that we can do whatever with publicized source code. However, if we think about other types of copyrighted work, say movies for example, streaming services can "rent" you a movie multiple times even though you've paid to download the content previously. What are you paying for the second time you rent? Another example - some photographers may allow you to freely browse their works, but they can still make you pay money if you want to use their photo in your commercial product.
So why wouldn't copyright restrict usage of source code in similar situations? The GP only needs to add a condition to the license to restrict how users can use it. It will no longer be OSS, but as long as it's his work, I don't see why in principle it shouldn't work.
(In practice, I don't think it will make much difference -- I think your argument is still somewhat compelling, and some people will probably take your position. Conservative corporate lawyers aimed at reducing legal risk would disagree, so it's basically a matter of how much legal risk one is ready to take. Also, for an author trying to do this, note that suing Microsoft in these cases would be expensive, since they will likely fight back given that they spent so much money trying to do this, and the outcome will be uncertain. If really tested in court, given the result of the Oracle v Google case, if the US Supreme Court is impressed by the social/economic benefits that Android brings, I'm pretty sure the justices will be even more impressed by this intelligent code generation thingy, and might just grant this thing a fair use.)
I have a nice strong lock on my door. GitHub (asserts that it) can enter my home through the window.
Adding another deadbolt to the door does not help.
Maybe I'm missing something (just not the thing you said), but has Github made any legal claims so far? The original article is written by a politician in EU...
Even if you're a lawyer defending Github in this case, there's still a couple things that needs to be clarified before you can make the case: (maybe the info is out there but I'm too lazy to research)
- Is Github only using code/repos that are explicitly under OSS licenses? (because if that's the case, then the discussion might be justified in presuming OSS terms, and it may be the case that more restrictive non-OSS licenses would require a different analysis)
- As somebody pointed out in another thread, the Github terms of service agreement seems to grant Github additional rights when dealing with user uploaded content. Is that a legal basis for the use?
And I tend to agree with you (and the other commenter) here. But GitHub doesn't.
> has Github made any legal claims so far?
I'm not sure how actively, but the CEO was here in the announcement thread the other day saying that they think the ingestion of the inputs is a "fair use". They also have some material defending the output side: https://docs.github.com/en/github/copilot/research-recitatio...
> Is Github only using code/repos that are explicitly under OSS licenses?
I don't think we know exactly what code they used as inputs, no.
It's a matter of scale. With a big enough codebase, there will be copyright violations.
The point (that they claim that) you are missing is that if "copyright is relevant to Copilot's input" then almost all existing OSS licenses already don't allow that.
However, GitHub said nothing about the output of the model being fair use. My license will say that the output of their model is under the same license as the input, which means they have restrictions if they want to distribute it (i.e., actually have people use Copilot).
I think this will work because it doesn't say that GitHub is wrong. Instead, it says that, even if GitHub is right, it doesn't matter.
It would also be very bad for GitHub to claim that the output of an algorithm can't be under the same license as the input because we feed licensed code to algorithms all the time and claim that their output is still under the same license. We call those algorithms "compilers" and the binary code they produce is still copyrighted and licensed.
I didn't mean to take a side or argue a position here. I was just pointing out that licenses hold no legal power in the event that copyright itself doesn't apply.
> ... So why wouldn't copyright restrict usage of source code in similar situations?
I'm certainly not an expert here but I believe you are mistaken about the extent to which current copyright law (in the US) restricts such usage. I also don't think that the examples you bring up are as simple as you seem to be making out.
You are legally permitted to record broadcast shows for later viewing; you are not permitted to redistribute the recordings though. I assume (but am not certain) that rentals and streaming are the same. (That being said, bypassing DRM has been made its own crime. This effectively amounts to an end run around the rights otherwise granted to you by US copyright law. But then there are specific exceptions where bypassing DRM is permitted. I digress.)
You aren't legally permitted to mirror the contents of a website (such as the New York Times) without permission but you are allowed to access it since they make it publicly available. You are even permitted to save a copy for your own purposes when you access it; you are not permitted to redistribute that copy.
For an extreme example, consider the recent LinkedIn case. Unless I misunderstood it, the court deemed it acceptable to scrape any publicly available content. Certainly most such scraped content was never explicitly licensed for that though!
Even if the license for a piece of code was entirely proprietary, GitHub presumably acquired it through legal means (ie intentional upload). Once they have it in their possession, it's not at all clear to me that current copyright law in the US has anything to say about how they use it (short of redistribution). Of course, if their ToS promises that they won't use it for other purposes then they can't do that. But assuming they never promised you that in the first place ...
There's a traditional argument here about needing a license to legally incorporate the copyrighted work of another into your own.
One possible counter argument is that training a model on publicly available work is analogous to a person viewing that work. So long as the model never outputs any of the original inputs (or only exceedingly small fragments of them that would fall under fair use regardless) it's not clear that those outputs constitute derivatives at all (in the legal sense). Or they might. The courts haven't weighed in yet as far as I know. (Consider GPT-3 or This Waifu Does Not Exist for additional examples of the sort of ambiguity that's possible here.)
Of course, one possible counter to that is that the model itself is (in many cases) effectively a lossily compressed copy of the original input works. So perhaps redistribution of the model itself would be a violation of copyright. But even if that turns out to be the case, it's still not clear that the output of such a model would run afoul of copyright.
I argue that the output of an algorithm has the same copyright as the inputs to the algorithm, and that's because we use compilers (algorithms) to transform source code all the time already, and no one says that the binary code (outputs) is not copyrighted.
The compiler produces more or less a direct (logical) translation so it's clearly some sort of derivative. We go from C to machine code but the output still "means" the same thing as the input. (More precisely, it's approximately a mathematically transformed subset of the original input. Lots of information is removed, things are reorganized, and a bit of extraneous information gets added in the process.)
For something notably more muddy than a compiler, consider This Waifu Does Not Exist. Any given output is (typically) nowhere near any particular input but you can often spot various strong resemblances.
Alternatively, the implementation of sketch-rnn (https://magenta.tensorflow.org/sketch-rnn-demo) is quite different - it outputs pen strokes instead of pixels. Still, the legal questions remain the same.
For a significantly muddier example, consider GPT-3. The outputs are (typically) not even remotely similar to anything that was input except in very broad strokes.
Where does Copilot fall along this continuum?
For even more confusion, consider running a New York Times article through Google Translate. Are you in the clear to publish that? I seriously doubt it.
But what about running it through an ML algorithm that (attempts to) produce a very brief summary of it? Many such implementations exist in the real world today. Their output is nothing like the input - should it still fall under the copyright of the original?
Finally, it's worth pointing out that for many of the above computerized tasks there are direct human equivalents. Art can be traced on a light table. A drawing can be produced that fuses the styles of two references. News articles can be manually translated or summarized.
Again, my intention here isn't to argue a particular side. I'm just trying to make it clear how complicated this stuff is and the fact that we don't have clear legal answers for most of it yet.
Tool that could be used to violate copyright := Gets prosecuted by MPAA and friends, legislation is passed to make use / development / distribution of such tools illegal
Bigcorp ships the ML equivalent of ALLCODE.tgz, but you actually gotta look in the no/dont/open/this/folder/gplviolations/quake.c folder := Is this adequate proof that copyright is being violated?
Can Copilot produce licensed code verbatim, in enough quantities to matter, with a license your business would be infringing? Yes. Can you easily tell by looking at the output? No. Could someone end up suing you over it? Maybe, if they cared enough to find out. Can you honestly tell your investors, or a company you seek to be acquired by, that nobody else can have valid copyright claim against your code? No.
Well aren't all your assertions exactly the point of contention?
How much code is enough to infringe is a tricky question, though. It's not only a function of size, but also of importance/uniqueness - and we know that Copilot doesn't understand these concepts.
As part of the sequences of rulings in Google vs Oracle, the 9-line rangeCheck function, in the entirety of the Android codebase, was found to be infringing.
But there is also actually an issue about laundering and what constitutes "use". But there is also de minimis to consider.
And EVERYTHING will depend on jurisdiction of course.
IANAL
It's an algorithm. In the olden days, you couldn't copyright an algorithm, even an original one. There's only so many ways you can express an algorithm; the best ways are using code. So is it the intention that rewriting in Python an algorithm previously expressed in C would be infringing? Suppose the algorithm is re-expressed in English?
Allowing copyrights on algorithms is tantamount to allowing copyrights on thought-processes.
Here come the thought-police. Take cover.
In the US, copyright may include the choice of variable names, the organization of the code into modules and functions, and other aspects which where there are the creative choices that may be protected under copyright law.
The relevant process is described at https://en.wikipedia.org/wiki/Abstraction-Filtration-Compari... , which comes from the court case at https://en.wikipedia.org/wiki/Computer_Associates_Internatio.... nearly 30 years ago:
> the court presented a three-step test to determine substantial similarity, abstraction-filtration-comparison. This process is based on other previously established copyright principles of merger, scenes a faire, and the public domain.[1] In this test, the court must first determine the allegedly infringed program's constituent structural parts. Then, the parts are filtered to extract any non-protected elements. Non-protected elements include: elements made for efficiency (i.e. elements with a limited number of ways it can be expressed and thus incidental to the idea), elements dictated by external factors (i.e. standard techniques), and design elements taken from the public domain. Any of these non-protected elements are thrown out and the remaining elements are compared with the allegedly infringing program's elements to determine substantial similarity.
Emphasis mine. This specifically highlights that your example ('only so many ways you can express an algorithm') is not protected under US copyright law.
The originality requirement only applies to other aspects of the generated code, which in this case would include the comments that Copilot generated, and which clearly are not required for the algorithm to work.
For thought police like you describe, look to patent law.
software patents?
Either way, the copyright of source code is separate from that. Copyright is for the text of a program (the source code), that might e.g. implement an algrithm. The algorithm itself cannot be patented or otherwise legally protected.
I've not come across your stipulation that for a thing to count as an algorithm it must provably halt, but I can go along with that. So I'd argue that in most cases, any function or subroutine provably terminates, even if the program embodying it is not supposed to terminate.
I also don't agree that an algorithm is "just maths". At least, not if you then pivot to saying that a browser isn't "just maths". Any operation performed by a computer is "just maths", because what a CPU does is basically arithmetic and branching.
I don't think it's a question of what does and doesn't "deserve" IP protection. The source code of a browser is clearly an original work, and entitled to protection. But the ideas and procedures it embodies are not "works", and copyright isn't supposed to apply to ideas and procedures.
I'm against the very idea of "intellectual property". It must have seemed a good idea at the time, but I think patents and copyrights have become monsters that inhibit, rather than encourage, innovation and creativity.
Algorithms are distinguished by their proofs of correctness. This elevates them above simple procedures. The halting problems tells us that there is no automatic way to determine whether or not a program terminates. So when we find one, it's like discovering a mathematical law. The proof of an algorithm's correctness is expressed independently of any programming language or platform. What else could they be other than math?
Things like browsers, games, operating systems, e-mail clients, music players etc. are not treated this way. They are not formally specified. They are implemented in the context of a machine and an actual running environment. The source code of the program usually doubles as its specification. It's very different compared to an algorithm.
I agree IP as a concept is bad, but this is the way of the world at least for now. Given where we are, for me it makes sense to draw a line between algorithms and software in the context of copyright.
Can you cite? (Wikipedia's explanation of what an algorithm is doesn't mention that). I'm open to being corrected, but not baldly contradicted.
Wikipedia does mention it though:
"Finite sequence", meaning it terminates. The wiki citation (The Definitive Glossary of Higher Mathematical Jargon) provides a little more: "A finite series of well-defined, computer-implementable instructions to solve a specific set of computable problems. It takes a finite amount of initial input(s), processes them unambiguously at each operation, before returning its outputs within a finite amount of time." https://mathvault.ca/math-glossary/#algoSo they stipulate finite input and output and finite runtime. This is in contrast to something like a webserver or OS, which has a potentially unbounded number of inputs, and is expected to run effectively forever.
I mean think about it, what does an OS kernel look like in its most distilled form? It's essentially just an entry point to an infinite loop. Same as games, where they're called "event loops" in that domain.
The way I think about it is this: if computers and programming languages and software didn't exist, algorithms still would. I don't think you can say the same about e.q. Quake. Quake isn't a mathematical truth even though it uses them to work, kind of like how engineers use physics to build a bridge, but the bridge itself isn't physics.
I don't see anything in the WP article about proofs of correctness. "Finite sequence" surely just means that the number of instructions isn't infinite? Come to think of it, that wording seems rather hand-wavey; I wonder if I can find citations to help me improve it.
Well how are you going to show that the algorithm terminates for all inputs without a proof of correctness?
Let's say someone comes up with a new sorting algorithm, which completes in less cycles than was previously believed possible. Sure, it's math, but isn't that a new, creative expression? Don't we want to encourage them to publish their algorithm (one of the key purposes of patents—this way, anyone can use it after 20 years), as opposed to keeping it hidden from the world?
It makes more sense to me than most software patents (admittedly, a low bar to clear). And if the patent office is doing its job (big if), the patents should only be granted for algorithms which are sufficiently novel.
But nowadays I think patent law isn't the right way to do that; trade secrets should be enough. I don't think that what is disclosed to the public in patent applications is of enough value to justify a long monopoly. It's not necessarily a problem with the written law; patents are horrible because of the way courts apply them.
Yes, a port from language X to Y is widely considered a derived work. Whether it is infringing is a separate question.
You can't copyright an algorithm, but you certainly can copyright the expression of an algorithm in Python. You cannot copyright the words of the English language and their meanings, but Noah Webster absolutely did copyright his dictionary, which was a creative expression of their definitions (and lobbied for the first increase to US copyright law). Webster wasn't the "thought police" for trying to copyright people's understanding of words in English, because he didn't and couldn't copyright them; he copyrighted his expression of what words meant.
If you read the creative expression of an algorithm in Python and then re-express it in English, then sure, copyright protection doesn't extend to that re-expression. But Copilot isn't doing that, it's quite clearly reproducing parts of the original creative expression of an algorithm, not the algorithm itself.
Here's an easy way to demonstrate it: open up a source file in any language other than C and try to get Copilot to spit out an implementation of Quake's fast-inverse-square-root algorithm. You will very quickly discover that Copilot doesn't "know" the algorithm; it only "knows" the specific creative expression of it (comments included).
https://news.ycombinator.com/newsguidelines.html
At any rate, I like it here; so I'll try to figure out how what I said was flamebait, and try not to say such things again.
Sorry.
[Edited upon re-reading]
It would be quite straightforward to write an additional filter that would check the generated code against the training corpus to exclude exact copies.
I think that was a big part of the Google Vs Oracle case - how much copying constitutes an infringement?
It looks like they made a fairly complex rubric to apply in the future, it appears it would be on a case by case basis.
The question that brings is that this was found because it is so famous, but what if it is repeating Joe Schmoe's weekend library project, but we will never know because its not famous?
https://docs.github.com/en/github/copilot/research-recitatio...
Every literally quoted part that could infringe appears at least 10 times in the training data
Clearly, "10 other people did it" is no defense at all.
That is "10 other people". (Although your point stands, since there doesn't (or at least shouldn't to the point of criminal espionage) be any strong impediment preventing one person from creating 10 different accounts.)
This is a code search engine with the ability to integrate search results into your language syntax and program structure. The database is just stored in the neural network.
It’s definitely an impressive and interesting project with useful applications, but it’s not an excuse to violate people’s rights.
I'm not sure if I would characterize as a "database stored in a neural net", but that is definitely something to deeply consider.
But it's also not exactly just a database. It contains contextual relationships as seen with things like GPT that are beyond what a typical database implementation would be capable of.
Intelligence is mysterious in the same way chemical biology is mysterious (though perhaps to another degree of complexity)... It's not mysterious in the way people getting sick was mysterious before germ theory. There's no reason to think there's some crucial missing phenomenon without which we can't even reason about intelligence.
You mean in the same way that google.com isn't "just a database"?
If Copilot isn't intelligent, then what makes it more special than a search engine? How is Copilot not just Limewire but for code?
I could understand the argument that, if Copilot really is intelligent or sentient or something like that, then what it is producing is as original as what a human can produce (although, humans still have to respect copyright laws). However, I haven't seen anyone even attempt to make a serious argument like that.
* AI searches for code in its neural-net-encoded database using your search terms (ex: "fast inverse square root")
* AI parses and generates AST from the snippet it found
* AI parses and generates AST from your existing codebase
* AI merges the ASTs in a way that compiles (it inserts snippet at your cursor, renames variables/function/class names to match existing ones in your program, etc)
* AI converts AST back into source code
Is AI intelligently producing new code in that example? Because I don't think it is.
What would be an interesting test of whether it can actually generate code is if it were tasked with implementing a new algorithm that isn't in the training set at all, and could not possibly be implemented by simply merging existing code snippets together. Maybe by describing a detailed imaginary protocol that does nothing useful, but requires some complicated logic, abstract concepts, and math.
A person can implement an algorithm they've never seen before by applying critical thinking and creativity (and maybe domain knowledge). If an AI can't do that, then you cannot credibly say that it's writing original code, because the only thing it has ever read, and the only thing it will ever write, is other people's code.
How do you differentiate between these two things?
If I take `for i in range(10):` from one place and `print(x * 2) from another place, and combine them to get
have I "produced" something or "combined" existing things?As an aside, your understanding of how the model works here is completely wrong. Like, just absolutely fundamentally completely wrong.
That's a contrived example because none of those lines could be protected by copyright, patents, etc. A better example might be if you started selling a 30 minute movie that was just the first 15 minutes of Toy Story spliced together with the last 15 minutes of Shrek. I'm not a lawyer, but I'm pretty sure that would qualify as a derivative work, meaning you're potentially infringing on someone's rights (unless they've given you permission/a license).
And to be clear, none of these problems are new. People have been fighting over copyright and it's philosophy in court for a very long time. The only thing that's different here is that it seems some people think it's ok to ignore copyright if you use Copilot as a proxy for the infringement.
> As an aside, your understanding of how the model works here is completely wrong. Like, just absolutely fundamentally completely wrong.
Of course I don't, it's a neural network. You don't know either. That example I posted could be exactly what it's doing, or not even close.
(although for the record, I wasn't trying to explain how copilot works in that comment. It was a hypothetical "AI" for the sake of discussion, not that it matters. My point about it being copyright infringement is the same even if that hypothetical implementation is wrong)
Well no. The question I'm asking about, the philosophical distinction between "producing" or "combining" is a valid question no matter the copyrightability of anything. It's an interesting philosophical question even if we presume that copyright is bubkis.
> It was a hypothetical "AI" for the sake of discussion, not that it matters.
Ah, my mistake. I see that now.
> Of course I don't, it's a neural network. You don't know either.
I may not know how to make a lightbulb, but I do know hundreds of ways not to make one ;)
What is this supposed to mean? We know how neural networks generate things like this very very well.
I personally have built a system that takes pictures of hand drawn mobile app layouts into the NN, then generates a JSON based description file that I compile into a Reactive Native and/or HTML5 layout file.
This was trivially easy in 2018 when I did it. It took me maybe 2 weeks engineering time, and I'm no genius. Our understanding of how transformer-based NNs work has come a long way since then, but even back then it was easy to show how conditioning on different parts of the image would generate different code.
This doesn't hold at all. Not many people can come up with an original sorting algorithm for example, but people write code all the time.
There is no database lookup.
I've attempted to break that part down here: https://news.ycombinator.com/item?id=27744156
But you seem to have a basic fundamental misunderstanding of what is going on inside the NN. There is no "search for code" - it is generating new code each time, but sometimes that code will be the same as something it has seen because there is little or no variation in the training data for that snippet.
The NN generates code token by token, conditioned on the code leading up to it (and perhaps the code ahead, similar to BERT).
If you see tokens like this you probably generate the same next token too:
You have conditioned your input on the code you have seen and the most likely token you produce is ":".That's what the NN does, but for much longer range conditioning.
Sounds like there is still a db lookup, just not at runtime and instead at build time of the NN. Can you clarify this please?
The issue here is that certain sentences (code segments) are memorized, and reproduced -- much like a language learner who completes every sentence which begins with "Mi nombre" with the phrase "Mi nombre es Mark". The regurgitation is based on high probability built into the priors, not an explicit lookup. A different logit sampling method (instead of taking the likeliest) reduces regurgitation, without changing anything else about the network. (It also makes nonsense happen more often, since nonsense items are inherently less likely!)
This is a massive simplification. It's adequate for most purposes, but when discussing at this level this simplification breaks down.
Tokens are stored, and the NN contains weights of likelihood of a token occurring after another, given a sequence of prior (and possibly post) tokens.
Verbatim retrieval usually means there is very little variation in the training data for that sequence, so the same set of weights gets stored.
So "retrieval" is actually the same generative process as unique code uses, but the NN hasn't seen any other versions.
Does it copy all the time? Doesn't matter. Plagiarism is plagiarism even regardless of it is done by a student in school, an author, a monkey or an "AI".
You wouldn't accept this from a student, you shouldn't accept it from a coworker (unless you are releasing under a compatible license) and of course you should accept it from Microsoft.
This should surprise no one who has seen the evolution of language models. Take a look at Kapathy's great write up from way back in 2015[1]. This generates Wikipedia syntax from a character-based RNN. It's operating on a per-character basis, and it doesn't have sufficient capacity to memorise large snippets. (The Paul Graham example spells this out: 1M characters in the dataset = 8M bits, and the network has 3.5M parameters).
Semantic arguments about "is this intelligence?" I'll let others fight.
[1] http://karpathy.github.io/2015/05/21/rnn-effectiveness/
They seem to believe it is a database system. That's really not how this works, and the fact it behaves like one sometimes is disguising what it is doing.
If I say "write a "for" loop from 0 to 10 in Python" probably 50% of implementations by Python programmers will look exactly the same. Some will be retrieving that from memory, but many will be using a generative process that generates the same code, because they've seen and done similar things thousands of times before.
A neural network is doing a similar thing. "Write quicksort" makes it start generating tokens, and the loss function has optimised it to generate them in an order it has seen before.
It's probably seen a decent number of variations of quicksort, so you might get a mix of what it has seen before. For other pieces of code it has only seen one implementation, so it will generate something very similar. There could be local variations (eg, it sees lots of loops, so it might use a different variation) but in general it will be very similar.
But this isn't a database lookup function - it's generative against a loss function.
This is subtle distinction, but it is reasonable that people on HN understand this.
How are these not both the exact same process of memory recollection? Can you elaborate on the difference between memory recall vs a generative process based on conditioning? I understand how these two are different in application, but not understand why one would say they are fundamentally different processes.
The best I can come up with is this:
Imagine you are implementing a system to give the correct answer to the addition of any two numbers between 1 and 100.
One way to implement it would be to build a large database, loaded with "x" and "y" and their sum. Then when you want to find out what 1 + 2 is you do a lookup.
The other method is to implement a "sum" function.
Both give the same results. The first process is a database lookup, the second is akin to a generative process because it's doing calculation to come up with correct result.
This analogy breaks down because a NN does have a token lookup as well. But the probabilistic computation is the major part of how a NN works, not the lookup part.
People have been trying to accomplish that for 65 years. We're not even close. It's the software equivalent of cold fusion (with less scientific rigor)
It has memorized one thing. That doesn't prove it's not intelligent. If anything it's the other way around, we would expect an intelligent being to be capable of memorization.
All I can think of is the Turing test and the AI effect. Eventually we will have an AI that is capable of writing code indistinguishable from a human, and people will STILL say it's "not AI" and "just a code search engine", etc. Obviously this isn't there yet, but it's clearly getting closer.
Is 5 a more intelligent answer than 4, because it is new? Copilot is an autocomplete engine, not creative writing.
Also when talking about rights, whether or not Copilot copies doesn't seem sufficient to make a call. For instance, if it has to be coerced by the programmer to produce these kinds of snippets in an obvious way, then it seems fine to lay the blame on the programmer similar to when using regular autocompletion (or copy+paste for that matter).
They are putting GPL code in non-gpled codebases. Is it okay to take sections of other people's source code and use it on yours, if you just got it as a suggestion?
Algorithms should not be subject to copyright, that way lies madness. It would prevent new generations from building on top of the work of their predecessors, because copyright lasts a very long time. The amounts of code that github copilot reproduces fall squarely into the “shouldn’t be subject to copyright” domain for me, even if they pass the bar for originality.
The algorithm is not copyrighted, but the source code of the function is copyrighted. You could learn how the algorithm works by reading the function, and then write your own function that implements the same algorithm. Algorithms are not copyrightable, they are not subject to copyright. Source code is copyrightable.
Copilot is not reproducing just the algorithm, it is spitting out large chunks of the copyrighted source code, verbatim.
https://www.beyond3d.com/content/articles/8/
It's such a famous snippet that it's even included in full on Wikipedia [2].
I wouldn't be surprised if the next version of Copilot filtered these out.
[1] https://github.com/search?q=0x5f3759df+what+the+fuck&type=co...
[2] https://en.wikipedia.org/wiki/Fast_inverse_square_root#Overv...
Do not go down this line of reasoning, otherwise we will be copyrighting the concept of for loops.
[Citation needed]
And then I saw your source code and in the late 80s I changed the variable names, function name, and logic to be x+y+z+0.1
And then I told my friend John that there's a super cool algorithm that adds numbers together, and he made some more changes to it and compiled it for a different platform...
Has anybody broken the law in your mind?
EDIT: because it would seem that the original authors (among them Cleve Moler) don't have any issue with what transpired
Is there a source that said they changed variable and function names and modified the logic?
> because it would seem that the original authors (among them Cleve Moler) don't have any issue with what transpired
Yet. Without an explicit license there is no basis to release it under the GPL (if the code was copied verbatim or had insufficient re-writing). What if the heirs of the copyright owner wanted to assert their rights? Is there a doctrine that if you don't assert your rights you lose them? (Presumably applies to trademarks, but I don't think this is the case for copyrights)
What do we do then? The burden of proof for infringement is on original authors, and they haven't done so for 40 years.
In the late 1700s and early 1800s, Britain had to take measure to prevent visiting Americans and others from memorizing the designs of their new high tech machinery like the steam engine and the power loom.
Where do we draw the line? Shut down the internet until we create a massive copyright detection firewall?
No, we live with the copying and constantly evolve and adapt our business. Death to all patent trolls.
I won't even claim that people must necessarily follow the law. Copyright law is inconsistent at best, and notoriously hard to follow to the letter (and often ridiculous). In practice lawyers assess the legal risk and weigh the outcomes.
I never intended to discuss what we should do, and I definitely did not propose shutting down the internet...
The original discussion was such:
> > They did not copy the implementation, they copied the general idea of what the algorithm should do
> [Citation needed]
You said the original authors did not complain, which is neither here nor there, as I pointed out. There is still some theoretical legal risk if you copy with the owner's knowledge but not express consent. The fact that the burden of proof is on the authors is true but that they have not brought a claim does not mean they cannot prove infringement.
And in case I haven't made it clear, I don't think it's a bad idea to assume the function is under GPL, I just don't think there's a basis for claiming what you originally claimed, and there is still some level of (probably acceptable) risk if you take the purported license of source code as-is.
> [Citation needed]
(Not really your point, as such, but) no, actually, if you claim they did something (nominally[0]) wrong, the onus is on you to provide citations showing they did it[1].
0: > From an IP absolutist standpoint
1: Well, or that they (voluntarily and explicitly) accepted some responsibility (such as a job as a police officer) that entails a higher level of scrutiny than innocent-until-proven-guilty, but that's not really relevant here.
Too late, patents pick up where copyright ends, to protect general algorithmic ideas, not just implementations. And we have lots of patents on things that seem trivial now, including for-loops (just see how many patents depend on “a multiplicity”). Look - here’s a helpful lawyer’s template for including for-loops as a claim in your own patents: https://www.natlawreview.com/article/recursive-and-iterative...
Another example is the famous XOR patent https://patents.google.com/patent/US4197590/en
EFF keeps a blog on stupid patents https://www.eff.org/issues/stupid-patent-month
Anyone who thinks that licensing will have an effect on what is happening in reality is severely misguided.
Free and open sound good to me! What do they mean exactly? I guess it’s a non-debatable fact that copyrights and patents are abused by many big companies and patent trolls, but doing away with the system does seem extreme, it has also protected deserving individuals on occasion, no? You are saying that it should always be legal to copy someone else’s code / inventions without giving them any credit or compensation?
> Anyone who thinks that licensing will have an effect on what is happening in reality is severely misguided.
I’m not sure I understand what you mean; lots of licensing activity does have a measurable effect on reality. This article is only a small example, but people get sued all the time over taking code and using it without licensing it.
A claim on a combination of elements in which one element is an iterative component is not the same as claim on all iterative components everywhere.
The thing about the situation is that "copying code you found on the Internet" certainly isn't automatically, always legal. That you engaged in copying X from the Internet doesn't make illegal either. Your source for the source code your incorporate into a product doesn't matter, what matters is whether that code is copyrighted and what the license terms (if any) are (and people saying "copyright doesn't apply to machines" are wildly misinterpreting things imo).
Given what's come out, it seems plausible that you could coax the source of whatever smallish open source project you wished out of copilot. Claiming copyright on that code wouldn't be legal regardless of Copilot.
Whether Microsoft/Github would be liable is another question as far as I can tell. I mean, Youtube-dl can be used to violate copyright but it isn't liable for those violations. The only way Copilot is different from youtube-dl is that it tells it's users everything is OK and "they told me it was OK" is generally not a legal defense (IE, I don't know for sure but I'd be shocked if the app shielded it's users from liability). All the open source code is certainly "free to look at" and Copilot putting that on a programmers screen isn't doing more than letting the programmer look at it until the programmer does something (incorporating it into a released work they claim as their own would be act).
The question is how easily a programmer could accidentally come up with a large enough piece of a copyrighted work using Copilot. That question seems to be open.
TL;DR; My entirel amateur legal opinion is that Copilot can't violate copyright but that it's users certainly can.
This is not a research project, this is a commercial work that produces verbatim copies of code without disclosing its license (or having a license grant in many cases). It doesn't matter how it manages to reproduce it either. It does.
But I still want to support small developers with anything I produce for fun, and I'm not willing to give that up to spite the big developers.
For instance, I wrote a small class to load OBJ files in Unity because I needed it for an idea. I went ahead and put it on Github for others that need it, too. I could easily see someone having an idea similar to mine that needed that and couldn't find it out there. (I think there are more libraries like that now, though.) I wanted them to feel comfortable using it, even if they eventually make money with their game.
If a big corp uses that code, too, that sucks. But there's no good way to draw that line in a license, so I didn't.
Having said that, in the future I could see releasing some software that I don't think anyone should profit from, and in that case I'd GPL it. Previously, I'd have just defaulted to the same MIT license. I'm just not sure what that'd be yet.
> But I still want to support small developers with anything I produce for fun, and I'm not willing to give that up to spite the big developers.
Another line of thought that may help you choose a license: Do not think only about other developers. Think about the final users of your code that will be running your algorithms on their computers. The GPL protects the right of these users to see and modify the code they run (your code). So-called permissive licenses, on the other hand, let middlemen to strip this right from your users.
Users of your code are in fact freer thanks to copyleft licenses.
There's many companies who release source code. I don't know enough to say if that makes the word "most" in your sentence false or not.
Anyways, a company using GPL code need not release all their own code. Just their modifications to that particular GPL program. And then again, only if they do intend to distribute the modified program.
Although I license all my amateur work GPLv3, I dispute the assertion that more permissive licenses are "nothing but" a redistribution of wealth upwards.
Permissive licenses commoditize their features. This is of benefit to everyone, but organizations with more capital are better positioned to leverage that commodity, and typically when they do, they do so selfishly. This further centralizes value with them, but I believe this is still a better outcome than a closed license because of the educational/cultural/technical benefits to everyone of the open license. The capital leverage problem is orthogonal to that.
Copyleft licenses kind of do the same commoditization thing, but explicitly only for share-alike uses, which is why they're the only way to grow open culture relative to proprietary culture: they're designed to deny "freeloaders" on open culture by requiring all derivative works to also be open.
> without any benefit to original authors
Benefiting the original authors is not (directly) the point of open source.
MIT: "Here's some code, go nuts."
GPL: "Here's some code, go nuts, but share the nuts if you do."
There's zero value capture for the original author built into these licenses. If the original author wants to ensure they capture the value from their work, I recommend using a closed, proprietary license. Just be aware they're applying friction to the overall technological development of humanity by doing so.
I don't really expect any benefit when writing some pieces of code. These days I just make certain types of code I make public domain, because if it's MIT then BigCorp inc. will just make my name one in a really long list of contributors, and I won't get any benefit either.
As a side note, in a not so distant future there may be decompilers enhanced by artificial intelligence.
This is fantastic news.
I'm going to create a bot that crawls sites like GitHub searching for popular libraries. Then it will copy them- sans any license- to it's own website where it will sell these libraries under a new name.
Since there is no creator here, just a piece of software, then there is no copyright violation. My system simply is "inspired" by the original source code using a proprietary algorithm that I call "Copy and paste".
I'm open to accepting venture capital for this project.
Does this include my Xerox machine? If so, is anyone looking for very very cheap textbooks?
The output of copilot is macnine-generated and is not subject to copyright. Microsoft cannot claim copyright on what it generates. That does not affect my rights, or anyone else's. I can claim copyright on what I write, and neither copilot nor your stupidity diminish my rights.
MS may argue that what copilot copies is small enough that I have no copyright on that, and win in court. You may put forward the same argument but I think your fate in court would be different.
What about when I, a developer working on a proprietary codebase, blindly commit the output code into our product? Have I created a derivative work or, worse, plagiarized?
If you reproduced code that's copyrightable and under another license, then yes you are in violation.
It will take a decade for the case to proceed to court and determine exactly what claims can be made against your company and GitHub.
In practical terms, you should turn off Copilot this very minute.
We aren't talking about a server sitting in a Microsoft data center shuffling code to another server without human intervention. We are talking about a tool that helps developers create code -- code that is "copyrightable and under another license", and thus in violation.
Then we'll see how fast Microsoft and others will shut it down.
Heise appears to be quite $bigcorp friendly recently.
"Simply"? If it were that simple, surely that would mean that the output of the Unix "cp" program would not qualify? What about a DVD copier?
I'm OK with copyright as it used to be, back when I was a teenager; the right expired with the author's life. Corporations couldn't own copyrights. There was no burden on the author to register their rights. And copyright was a civil matter; you sued for actual damages. Infringement wasn't a crime.
I'm not OK with modern copyright law, with criminal penalties, rights that can be transferred to entities that are essentially immortal, and copyright terms that keep getting extended, just before Mickey Mouse and Elvis Presley become public domain.
> "Simply"? If it were that simple, surely that would mean that the output of the Unix "cp" program would not qualify? What about a DVD copier?
It means that the output of "cp" does not qualify for copyright protection as a derivative work. The output is still a copy of the input and would be subject to the same copyright as that input.
Roughly, a derivative work is a new work that incorporates some copyrightable elements from a previous work. The derivative work gets its own copyright separate from the copyrights of those incorporated elements.
By this logic:
- someone could go and copy functions and/or entire files from GPL code bases and use them with a different license.
- someone could use copilot or similar to learn from all available GPL code. Is resulting code GPL?
- someone could use copilot or similar to learn from open source code of their competitors that license doesn't allow them to use. Are the results legal?
The copyright status of a derivative work is a separate issue: A derivative work can be considered infringing, and a derivative work can be considered non-infringing (ie. due to Fair Use).
http://digital-law-online.info/lpdi1.0/treatise26.html
I’m not arguing for/against: I just think a straight copy was not what the author intended to be included by that statement.
No; the author spends some time asserting that the output of a machine is inherently not a creative work:
> Machine-generated code is not a derivative work
> the argument that the outputs of GitHub Copilot are derivative works of the training data is based on the assumption that a machine can produce works. This assumption is wrong and counterproductive.
> This means that machine-generated code like that of GitHub Copilot is not a work under copyright law at all
I think we can assume the author doesn't believe that piping bytes through the 'cp' command automatically removes copyright (as the person I replied to suggested).
And HN rallies to criticize it because Copilot can reproduce some snippets when forced to.
That is an appeal to authority. Being a legal expert does not excuse one's writing from critical analysis. In this case, the post does not address Copilot reproducing large segments of copyrighted code verbatim. That is valid criticism.
There is no logical fallacy since HN refuses to even have a logical discussion about Copilot.
For example, GitHub license section D.4 specifically grants GitHub the right to display your content, analyze your content, and reproduce it in full to other users of the service. Yet no one seems particularly interested in discussing that here today, because it isn't compatible with the outrage that people are prioritizing on HN when discussion Copilot.
I would have expected HN to be better than Reddit in this regard, but I'm not seeing it yet. I don't know if the expert is right or wrong here, but nothing in today's comments suggests anything new or curious that hasn't already been ranted about in every prior thread about this topic. I specifically care about copyright law and it's disappointing to see HN having a group tantrum instead of a discussion.
https://docs.github.com/en/github/site-policy/github-terms-o...
I'm actually sort of curious as to the vigor of the backlash. Because Microsoft? Because of concerns about perceived further undermining of the GPL in particular? Because of people anxious to get their credit? Because...?
Because, this is really against the understanding of what was possible for copyrighted works. So, now that this is possible for anyone, copyright will start to get examined and hopefully updated to be useful in today's environment.
There are about a million problems with this.
This can even be used to intentionally launder source codes from a competitor. Apparently, all it will take will be to steal code (or just fork it), then create more than 10 copies on Github. At that point, copilot will start to emit the code during use. With all the legal commentary saying this isn't infringement, imagine how companies will be able to use this product.
Similarly, the training set can be intentionally polluted, so your competitor finds the output of Copilot worthless.
(Why do they care so much about revenue? Open source coders and ‘starving artists’, not to mention Covid economic wreckage, the US approach to medical insurance, and the total absence of Universal Basic Income in virtually all countries permitted to access GitHub.)
Well, Copilot isn't really an analaysis and display of the source code within the original meaning that people held. That was meant more to run codeql, github actions, and other analysis while presenting the results in a repository to people. People never anticipated that github would strip their licenses from files and present their source code inside of VSCode for people to use freely. It may be legal, but what we are seeing now is an abuse of the sentences you just quoted that goes outside what they were originally understood to mean.
Is it fair use to autogenerate GIFs from movies, perhaps the most protected digital works on the Internet today, in order to use them as reaction memes on Imgur?
Is it fair use to autoextract code fragments from a code base, in order to use them as suggestions on GitHub?
The Internet, and I imagine HN, was in an uproar when the music industry attempted to kill the White Album, because it infringed on their freedom to remix and derive.
The Internet, and I imagine HN, was in an uproar when MLB attempted to kill unauthorized baseball GIFs and replace them with official curated ones, because it infringed on their freedom to remix and derive.
How, precisely, is remixing and deriving from code ‘abusive’, in contrast to the past ten or twenty years of pressure on the Internet to the contrary when remixing and deriving from music or movies?
This is a core point of the original post linked above, where the author is shocked by our demands for more prohibitive copyright interpretations, and I want to call this out more bluntly and less politely than they did:
Fair use of a work is almost always perceived as abusive and unfair by the creator of a work. Creators ignore the cognitive dissonance between their demand to have fair use rights granted more easily to the protected works of others, and their demand to have fair use rights granted less easily to their own protected works.
I see that dissonance go unaddressed in every top-level comment in today’s discussion. I see that desire to deny fair use rights driving hundreds of emotional me-too posts, without considering the framing of whether it is fair use in alignment with every prior copyright outrage we’ve discussed over the years.
My theory is that permitting discussion of fair use would weaken their efforts to groundswell a pitchfork mob, and no one wants to confront their own biases or emotional investment or inability to profit from their code.
Whatever the motivations, HN deserves better than this.
> People never anticipated that github would strip their licenses from files and present their source code inside of VSCode for people to use freely.
I can’t offer you a more detailed mapping of my reply onto exclusively your talking points, as I didn’t consider that a viable constraint. My original point at top of thread remains clear on my mind as I try to provide - using the examples of my own questions and concerns, after objections in the past that I wasn’t! - of what better, more reasoned, more curious, more worthwhile conversation looks like on this topic.
I do accept that not everyone desires to see the change in tone I’m trying to represent here, and no doubt I have been imperfect in my efforts to represent it. I’m sad that this isn’t connecting for you, even though I accept each time I try this that understanding and agreement are never universal. Thank you for your effort in trying to understand all the same.
None of the other examples match up because the GIFs are not being compiled into films. The remixed works are in a different field of endeavour.
If Copilot were being used to show snippets that scroll across the screen in hacker films, or used by musicians to rap a few lines of Rust code, that would be palatable to the copyright holders. It is transformative and very likely to be fair use.
If Danger Mouse, who created the Grey Album, had instead started a business selling access to a tool that splices in copyrighted music and video based on a clip that the user provided, facilitating widespread, systematic infringement, creators would have been far less sympathetic, and EMI far more persistent in their legal attempts shut it down and collect damages.
If Danger Mouse sold a remixing tool that enable widespread remixing of any/all albums, would DM be profiting illegally from the content of others?
In each individual case, the remix album produced would have to pass the fair use tests, and if the user produced a sufficiently close replica, they could be restrained from distributing it. But that wouldn’t implicitly be the remixing tool’s fault, unless it mechanically reproduced a complete protected work with the user completely unaware it was doing so. A dedicated user can make any tool produce a protected work, so we have to aim for the narrow window of user-oblivious in order to fault the tool.
Translating back to Copilot, this then becomes the question: can Copilot regurgitate an entire protected work for a user who then sells that work, with the user being fully unaware that they have reproduced a protected work without meeting fair use terms, such that Copilot is responsible?
Copilot requires user prompting to emit code, and seems to draw the line at around the single function boundary, so reproducing an entire codebase becomes exponentially less likely as the number of functions increases.
So if there were a weakness in Copilot’s defense, it would be in small single-function programs, at which point the parallel to another music case comes to mind: the person who generated and copyrighted every single musical phrase in Western major/minor, to prove that the law as written is not applicable when the total size and complexity of a given work falls below a certain threshold. I thus assume that Copilot is essentially protected in the single function case - it doesn’t matter if you have a protected work for (‘four’ (2 2 +) func), because that’s so simplistic that any human might reproduce it at any time unaided, and so claiming against them would fall flat when a judge applies the common sense threshold. It’s a high bar to expect a judge to recognize this analogy and understand code well enough, but I think between user intention to break fair use being required for complex multi-function systems, and the protection of snippets being essentially impossible to enforce against in music terms, would absolutely shield Copilot from being judged liable and owing damages.
(General disclaimer applies: I am not your lawyer, please seek legal counsel before making use of my opinion, etc.)
How applicable is the Github license when a lot of code on Github (let's say eg. the Linux kernel) was posted there by people other than the individual copyright holders? I'd assume they can only rely on the open source license of the code in question, and not really on additional license terms. As far as I can tell, Github claims fair use rather than citing their license.
You missed the comment on this page, 4 hours prior to your comment, that mentioned this. It's difficult to take your comments seriously.
> D.4 specifically grants GitHub the right to display your content, analyze your content, and reproduce it in full to other users of the service
If you read the section carefully, this covers the right of GitHub to do those things to your content "as necessary to provide the Service". "It also does not grant GitHub the right to otherwise distribute or use Your Content outside of our provision of the Service".
So, does "Service" only cover the type of Github's service at the time of the agreement, or does it allow Github to invent all kinds of unrelated services and use the code as such? If Github can provide a "Copilot" service that arguably "learns" the code, can it also provide a service that blatantly "copies" large pieces of source code for the user (without complying to OSS license terms)?
It's not very clear what the answer would be, but if what I described is allowed, the consequences of this term being so broad would imply that if you're not the copyright owner of code you uploaded to Github, you've probably violated some OSS license by agreeing to Github's terms.
If you can reproduce a verbatim copy of Quake source code after taking that source code as input before then that's compression. A really fancy, but still.
And given that it reproduces the source code: it has to hold that somewhere.
It would be very interesting if someone could reproduce the Quake example with AGPL code, then request the whole model + code because it clearly contains the AGPL code in some encoded form.
This is a great legal question as it concerns our use of machine agents. We can learn from copyrighted literature or code that we read. Why can't our agents?
What you can't do is copy all of the creative expression in the original (such as comments) without complying with the terms of the license. Moreover, reproducing the magic constants is a strong indication that your process didn't independently derive your code because the constants used in the original are unique and non-optimal.
Not everywhere. Emulators communities often prohibit people from contributing if they've read the original code to protect themselves from copyright claims.
Many types of compression produce a compressed file larger than the original for input data that is not easily compressed. Just because a compressor is bad at compressing (some) inputs, doesn't exclude it from being a compression algorithm.
Training is the process of creating a space where searching for the right thing within it gives you the answer to some problem you have.
Copilot has the ability to produce Quake's source code nearly by itself. And it's a work (not a person), so it can be seen as a derived work. Like a compression algorithm that sometimes tacks on the first paragraph of "50 Shades of Grey" at the end of files.
I'm not a lawyer, but that's my opinion (admittedly, my opinion is softening each day). Plus, the purpose of the tool is to create code for inclusion in projects somebody will hold a copyright over, and they likely won't be the original authors. So it's output should be held to a higher standard than a compression algorithm or keyboard.
Was it fed the Quake source code while training? Then it's not producing that code, it's just reproducing it, like a fancy (but imperfect) copy machine.
I'm not sure it's accurate to say that the training source code is "compressed" in the parameters of the model, but certainly some approximation of the training source code is stored in the parameters.
So if I rule that out, where does it end up? What if we put this as the grown up ML brother of the chain of LZW, PPM, dictionary assisted compression (e.g. zstd) and various attempts at using neural networks for compression?
I would not want to judge this - that's why I put up the AGPL idea. Or even unlicensed code. It would be a very interesting case to watch.
What? Where does the distinction between data and algorithm go with compression algorithms?
In its most abstract form a compression algorithm is function `{0, 1}^n -> {0, 1}^m` such that n < m and the output string is the result of something previously encoded.
Why can't the input string be the seed used to make the machine learnt model generate the Quake source code?
As a subtitle is to a movie, the quake "output" might be much smaller than quake itself.
Well, Microsoft, show us you believe your own arguments!
The article does not set itself up to address this at all:
> Since Copilot also uses the numerous GitHub repositories under copyleft licences such as the GPL as training material, some commentators accuse GitHub of copyright infringement, because Copilot itself is not released under a copyleft licence, but is to be offered as a paid service after a test phase.
I'm all for discussion of whether Copilot itself has to be copyleft. But to me, the immediate concern is that Copilot seems like a way to take copyleft works and remove the copyleft license from those works.
[1] https://mastodon.social/@cjd/106513694972486353
GPL does not permit you to copy source code without attribution. this copier does not provide attribution.
as i just said, i'm not so interested in debating the source-code-copier's licensing. i think it could go either way but i don't really care. the copied source code that the source code copier copies is interesting to me, and feel like the stochiastic parrot act bullshit they are pulling is massive massive sinfully evil bullshit without attribution. the stochiastic parrot can't just ignore all the licensing of what it parrots out.
Wolfram disagrees, and he's got lawyers and money too. Whom do we believe?
http://www.groklaw.net/article.php?story=20090518204959409
(I'm still not sure I agree with Reda, but the point is at least arguable under European law and depends on the circumstances).
Heck, the duration of copyright isn't even uniform around the world.
[1] Collage (/kəˈlɑːʒ/, from the French: coller, "to glue" or "to stick together";[1]) is a technique of art creation, primarily used in the visual arts, but in music too, by which art results from an assemblage of different forms, thus creating a new whole.
It is not astonishing at all given:
* proprietary codebase have not been indexed by copilot (at least a public version of it)
* arguably derived code will be used in proprietary programs
Copilot ought only to have indexed public domain, wtf, and other wide-open licensed software. They should remove all GPL'd software from their model, even if that means retraining from scratch.
Have we reached the point where every “class X” must become “class X_GPL2_CopyrightJohnQSmith_AllRightsReserved” in every code base out there? Do we need to go from header comments at the top of a file to reminder comments at the end of every line?
Or put differently, as a GitHub customer, are you comfortable with your code being used this way? Instead of a passive host, your code is now being used to create tremendous value for GitHub and Microsoft. Do you feel your trust has been violated? (regardless of legality).