-
Notifications
You must be signed in to change notification settings - Fork 1.6k
Add AI policy to contributor guide. #6618
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change | ||||||||||||||||||||||||||||||||||||||||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
|
|
@@ -21,3 +21,15 @@ To get the CI `rustfmt` job to pass, do either of: | |||||||||||||||||||||||||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||||||||||||||||||||||||||
| - Configure your IDE to format on save, and make sure it uses nightly rustfmt, for example by copying `rust-toolchain-nightly.toml` into `rust-toolchain.toml`. | ||||||||||||||||||||||||||||||||||||||||||||||||||||||
| - Run `fmtall.sh` before committing. | ||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||||||||||||||||||||||||||
| ## AI Policy | ||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
|
||||||||||||||||||||||||||||||||||||||||||||||||||||||
| - Using AI / LLM to write code is **allowed**. | ||||||||||||||||||||||||||||||||||||||||||||||||||||||
| - You **must** disclose AI usage in the PR description. | ||||||||||||||||||||||||||||||||||||||||||||||||||||||
| - You **must** review and understand every single line of AI-written code before submitting the PR, and be prepared to answer questions and make fixes to it. | ||||||||||||||||||||||||||||||||||||||||||||||||||||||
| - Fully autonomous agents like OpenClaw are **NOT allowed**. Every issue, every PR must have a real human behind it. | ||||||||||||||||||||||||||||||||||||||||||||||||||||||
| - Using AI / LLM to write PR descriptions, commit messages, comments, or replies to reviewers is **NOT allowed**. You must write them yourself. AI must not replace human-to-human communication. | ||||||||||||||||||||||||||||||||||||||||||||||||||||||
| - If you need help writing English, consider using a traditional translator like Google Translate instead of LLMs. They do a great job without the pitfalls of LLMs (overly verbose text, hallucinations, etc.). | ||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Google translate now enables its "advanced" mode by default when translating some languages, this mode uses an LLM and suffers from the same LLM flaws... This means hallucinations could occur. I sadly don't have a good alternative to recommend.
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I can recommend DeepL as a potential alternative. |
||||||||||||||||||||||||||||||||||||||||||||||||||||||
| - Low-effort pull requests are **NOT allowed**. Don't simply paste the issue text into an LLM and submit the result. It will most likely be a bad contribution. If fixing the issue was so easy, the person opening the issue or a maintainer would've already done it. | ||||||||||||||||||||||||||||||||||||||||||||||||||||||
| - Consider the time it takes to review your PRs. Maintainer time is the most scarce resource in the Embassy project. Keep diffs minimal, ask first before doing thousands-of-lines refactors, split PRs if you can. This has always been good practice, but it's especially relevant now that LLMs make it too easy to generate mountains of code. | ||||||||||||||||||||||||||||||||||||||||||||||||||||||
| - Pull requests not following this policy will be closed. | ||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Not sure if this should be so strict, a There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Stuff like this is to set a clear boundary for maintainers to be able to act without having to weigh every PR for "usefulness" if it fails to meet the requirements set by the contributor's guide. Being willing to enforce one's code of conduct is vital to maintain community health. If something is that trivial & also useful enough, then the code can easily be redone by a maintainer or picked up by another contributor.
Comment on lines
+25
to
+35
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I would add a short preamble that sets out the intention and the goal before listing the individual rules. (patch display might end up being crappy here. this is not a rewrite of the rules, mostly a reordering/regrouping)
Suggested change
|
||||||||||||||||||||||||||||||||||||||||||||||||||||||
Uh oh!
There was an error while loading. Please reload this page.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
A bit too strong? And for a largish PR I don't think that would be the case anyway. Even if the human claims he did it, probably he didn't. A code review theater.
How about:
"You must thoroughly understand the AI-generated code, and be prepared..."
or
"You must understand all AI-generated code in the PR, and be prepared..."
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
How do you understand something that you did not review?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
"...every single line"?