feat(policy): refine AI policy for new contributors#838
Closed
feat(policy): refine AI policy for new contributors#838
Conversation
Remove the blanket ban on AI-generated refactoring PRs: these may be useful. (All other caveats still apply, but this gives us more flexibility in practice.)
grunweg
commented
May 6, 2026
|
|
||
| We do not accept pull requests opened by new contributors where code is LLM-generated. Mathlib intentionally has very high standards (on generality, integration with the remaining library and maintainability, including code style). As of April 2026, AI-written code fails to meet that bar by a large margin. Getting code to mathlib's standards requires understanding and writing Lean code by hand. If you just want to help and not put in the learning effort, making a PR to mathlib is counterproductive: the effort required from the mathlib maintainers is larger than the benefit, because the time used to improve the quality of the code will not result in a better quality in future PRs. More generally the reviewer team may close a PR containing low-quality code if it appears to be AI-generated. If we notice that you open several PRs without putting in this learning effort and without adhering to our community ethical standards, we retain the right of banning you both from opening new PR's and from the Zulip chat. | ||
| We do not accept pull requests opened by new contributors that add new definitions or theorems where code is LLM-generated. | ||
| Mathlib intentionally has very high standards (on generality, integration with the remaining library and maintainability, including code style). As of April 2026, AI-written code fails to meet that bar by a large margin. Getting code to mathlib's standards requires understanding and writing Lean code by hand. If you just want to help and not put in the learning effort, making a PR to mathlib is counterproductive: the effort required from the mathlib maintainers is larger than the benefit, because the time used to improve the quality of the code will not result in a better quality in future PRs. More generally the reviewer team may close a PR containing low-quality code if it appears to be AI-generated. If we notice that you open several PRs without putting in this learning effort and without adhering to our community ethical standards, we retain the right of banning you both from opening new PR's and from the Zulip chat. |
Contributor
Author
There was a problem hiding this comment.
Suggested change
| Mathlib intentionally has very high standards (on generality, integration with the remaining library and maintainability, including code style). As of April 2026, AI-written code fails to meet that bar by a large margin. Getting code to mathlib's standards requires understanding and writing Lean code by hand. If you just want to help and not put in the learning effort, making a PR to mathlib is counterproductive: the effort required from the mathlib maintainers is larger than the benefit, because the time used to improve the quality of the code will not result in a better quality in future PRs. More generally the reviewer team may close a PR containing low-quality code if it appears to be AI-generated. If we notice that you open several PRs without putting in this learning effort and without adhering to our community ethical standards, we retain the right of banning you both from opening new PR's and from the Zulip chat. | |
| Mathlib intentionally has very high standards (on generality, integration with the remaining library and maintainability, including code style). As of May 2026, AI-written code fails to meet that bar by a large margin. Getting code to mathlib's standards requires understanding and writing Lean code by hand. If you just want to help and not put in the learning effort, making a PR to mathlib is counterproductive: the effort required from the mathlib maintainers is larger than the benefit, because the time used to improve the quality of the code will not result in a better quality in future PRs. More generally the reviewer team may close a PR containing low-quality code if it appears to be AI-generated. If we notice that you open several PRs without putting in this learning effort and without adhering to our community ethical standards, we retain the right of banning you both from opening new PR's and from the Zulip chat. |
Contributor
Author
|
Alternative proposal at #840. |
Contributor
Author
|
Closing in favour of #840. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Remove the blanket ban on AI-generated refactoring PRs: these may be useful. (All other caveats still apply, but this gives us more flexibility in practice.)