You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
and the [leanprover-community GitHub organization](https://github.com/leanprover-community/).
85
85
86
-
To clarify the above: actions that can result in suspension or banning from the Lean community Zulip include harassment, discriminatory or disrespectful behavior, sustained off-topic or disruptive posts, repeated low effort posts, use of the community to complete coursework or work tasks, use of sock-puppet accounts, DM spam, unsolicited mass DMs to users, significant use of AI without attribution, posting of "slop" AI-generated code accompanied by unjustified and incorrect claims about said code, and ignoring moderator guidance. This list is not exhaustive and the maintainers retain broad discretion in user moderation.
86
+
To clarify the above: actions that can result in suspension or banning from the Lean community Zulip include harassment, discriminatory or disrespectful behavior, sustained off-topic or disruptive posts, repeated low effort posts, use of the community to complete coursework or work tasks, use of sock-puppet accounts, DM spam, unsolicited mass DMs to users, significant use of AI without attribution, unrequested posting of "slop" AI-generated code, making unjustified and incorrect claims about AI-generated code, and ignoring moderator guidance.
87
+
88
+
This is not a free code review service. Posts that amount to 'look at my project' without a specific question or prior community involvement will be removed and the poster suspended.
89
+
90
+
This list is not exhaustive and the maintainers retain broad discretion in user moderation.
87
91
88
92
Repeated violations will result in temporary suspensions, which will increase in length if the behavior continues. Egregious individual incidents will result in bans.
Copy file name to clipboardExpand all lines: templates/contribute/index.md
+13-1Lines changed: 13 additions & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -61,6 +61,14 @@ style violations documented in this guide are welcome. Other stylistic PRs that
61
61
approval by the authors of the affected files may be closed. We invite authors to instead discuss the proposed
62
62
change on Zulip and, when significant consensus among reviewers is reached, to open a PR to the style guide.
63
63
64
+
## Use of AI
65
+
66
+
Using artificial intelligence tools to generate code is becoming more and more common. While this can be practical, their use also poses ethical, ecological, legal and social concerns. We recognise that there are strong differences in opinion on this topic, and do not enforce a strict ban. That said, while individual action alone will not address these concerns, we ask you to consider the effects of your AI use and if it is truly necessary.
67
+
68
+
If you use artificial intelligence (such as, by using github's copilot mode, asking an LLM like ChatGPT or using an agent like Codex, Claude or Gemini), please explain this in the PR description. Explain which tool(s) you used and how you used it. This provides useful context for reviewers: tools make different mistakes than humans, so knowing this makes it easier to spot common errors.
69
+
70
+
It is essential that you can vouch for all the code submitted in a PR, and understand all the content written by an AI. If you don't, then it is possible that the PR actually has negative value to the community, and you are expecting others to do the real work for you!
71
+
64
72
## Working on mathlib
65
73
66
74
We use `git` to manage and version control `mathlib`.
@@ -154,11 +162,15 @@ Labels can only be edited directly by "GitHub collaborators", which is approxima
154
162
However, anyone can add/remove the labels below by writing the following commands in a comment on the PR (each on its own line):
155
163
-`awaiting-author` will add the **"awaiting-author"** label
156
164
-`-awaiting-author` will remove the **"awaiting-author"** label
165
+
-`awaiting-zulip` will add the **"awaiting-zulip"** label
166
+
-`-awaiting-zulip` will remove the **"awaiting-zulip"** label. Use this once a decision has been reached and has been implemented.
157
167
-`WIP` will add the **"WIP"** label
158
168
-`-WIP` will remove the **"WIP"** label
159
169
-`easy` will add the **"easy"** label
160
170
-`-easy` will remove the **"easy"** label
161
-
- Similarly, the labels for use by contributors upstreaming work from the downstream projects **brownian**, **carleson**, **CFT**, **FLT**, **sphere-packing** and **toric** can also be added and removed in the same way.
171
+
-`help-wanted`, `-help-wanted`, `please-adopt`, `-please-adopt` can be used to mark a PR in need of external input.
172
+
- Similarly, the labels for use by contributors upstreaming work from the downstream projects **brownian**, **carleson**, **CFT**, **FLT**, **infinity-cosmos**, **sphere-packing** and **toric** can also be added and removed in the same way.
173
+
- Any topic label of the form `t-*` (e.g. `t-topology`), as well as the labels `CI` and `IMO`, can also be added and removed in the same way. PRs are auto-labeled based on their contents, but sometimes the auto-labeling is incorrect or incomplete so this lets you manually override it. See [available topic labels](https://github.com/leanprover-community/mathlib4/labels?q=t-).
162
174
163
175
This list is exhaustive. If you would like to add a different label, please, bring it up on Zulip!
Copy file name to clipboardExpand all lines: templates/contribute/style.md
+7Lines changed: 7 additions & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -740,3 +740,10 @@ We allow, but discourage, contributors from simultaneously renaming declarations
740
740
In this case, no deprecation attribute is required for X, but it is for W.
741
741
742
742
Named instances do not require deprecations. Deprecated declarations can be deleted after 6 months.
743
+
744
+
### Avoid `nonrec`
745
+
746
+
The `nonrec` keyword tells Lean to assume that apparently recursive calls in the declaration body
747
+
are not actually recursive, and instead look for declarations in other namespaces with the same name.
748
+
Avoid `nonrec` when the recursive call conflicts with another declaration *in a namespace*, because then adding the namespace to that declaration is more informative (to both Lean and the user). If it conflicts with a declaration in the root namespace, then both `nonrec` and `_root_.[...]` are acceptable. Sometimes avoiding `nonrec` requires forgoing the use of dot notation within the body of that declaration.
749
+
(There are currently many places in Mathlib that break this rule.)
0 commit comments