Guidelines for Use of AI #1920
Replies: 10 comments 26 replies
|
I agree its time for some guidelines. I think being able to explain your PR in (mostly) your own words is important, its very frustrating when someone just copies and pastes wholeheartedly the output from AI , and you know they did not bother actually checking if its a) correct and b) actually consumable by others (AI slop). I find this reverses the burden for issues and PRs, it costs nothing (in terms of time) for someone to ask AI to generate a long winded explanation for something, but shifts the burden now to those who have to read it and try a pick apart its validity (when a couple of well crafted sentences would have done the job). I have no idea how to turn this into guidelines, so this just may be me ranting..... |
|
I must say that I think the above proposal is too lenient on PRs. "AI assisted" in the form of suggestion, chat discussing how to do something etc. is fine, as long as the human is the author. Whole sections created by AI is not IMO, unless we're talking about creating boilerplate starting points for the "real content". It's just too hard to judge the quality. Think of it like you're out to buy a new lawn mower (traditional, not one of those "smart" ones that spy on you). The way it has been "without AI", you can judge the quality to some extent by looking at it, you can see what mechanical solutions have been made, what materials have been used, and know quite a bit already. Combine that with what you can find out about the brand, and you're probably in a reasonable place to judge it. You don't ever have to wonder if the piston is mounted up-side-down, or if the whole engine is just a mock with a loudspeaker that makes an engine sound when you "start" it. If it was made by "AI", you can't make any of these assumptions. Most of the engine can be valid, but it might entirely lack the crankshaft. Or, it has no bearings. Or the oil channels aren't drilled all the way through. To evaluate an "AI made" lawn mower, you have to pick it completely apart, inspect every nut and bolt, check the actual design of the engine parts, the materials used, calculate the forces various parts will be subjected to, in short, you'll have to do an examination that is more laborious that it would have been to make your own lawn mower in the first place. I have no faith that reviews will be that thorough, it's not reasonable to expect. That means that we either reject all such content, or we end up letting a lot of "slop" through. I'm very skeptical that it is at all possible to quality ensure "vibe coded" content. |
|
The wording sounds good to me, and it gives some guidance in a quick changing world of AI. I appreciate it! Good proposal! |
Perhaps we should also add an "AI" label (or similar) as a way of "declaring" fully AI-generated issues (and PR's). This would also make it possible for maintainers (and others) to add the label when reading something that is clearly AI-generated. I see more and more of this recently, and it would make it easier to exclude such issues and PR's when viewing lists. Personally I tend to prioritize fully AI-generated content lower, at least when I assess it as plain lazy, and when I would quickly spend more time than the person instructing the AI did. It seems we all agree so far on the requirement to disclose the use of AI (at least when fully generated, not just assisted) - perhaps we should already try to phrase this into our templates? |
|
Thanks for starting this, @florian-h05. I support having clear expectations, but I’d frame them around contributor responsibility and contribution quality, not around mandatory AI declarations. AI-assisted and AI-generated code is normal nowadays, and that alone should not be the deciding factor. What matters is that the contributor is the responsible author: they understand the change, can explain design decisions, respond constructively to review, and have actually tested what they submit. For me, the bar should stay the same regardless of tooling: if a PR is low quality, untested, or the author cannot reasonably own it, maintainers may close it. If the author demonstrates ownership and quality, we review it as usual. I would therefore avoid making declaration of AI usage mandatory. Optional transparency is welcome, but enforcing disclosure is hard in practice and risks focusing on process signals instead of code quality and accountability. Disclaimer: The text above has been created with the assistance of AI, but I am fully behind the content and it 100% represents my opinion. 😉 |
|
I am also thinking about adding a short section about maintainer responsibilities:
The motivation for this is to make it clear that AI reviews don't replace human reviews, and to ensure contributors are "protected" from incorrect claims of an AI by either disclosing the use of AI or checking the correctness of the generated review. |
|
One thing I wanted to add to this conversation is that in addition to having a policy for AI, what, if anything, can be done to make it easier for contributors overall to contribute in a way that:
Not every commit and contribution is going to require super high levels of reasoning and involve subtle feats of logic. A pretty standard "interact with this REST API" type add-on should be pretty straight forward and relatively easy for a contributor to create and submit. So is there anything that can be done, in addition to setting an AI policy in documentation only, to make it easier for contributors to do it right? I'm just getting started on an experiment of having Gemini build an add-on for me, basically starting from scratch (i.e. I didn't even have Java installed). I can report back with my findings if you all think it's relevant to this discussion. Some of the ideas I'm thinking of (some of which may already be in place:
I'm literally just getting started, so my ideas are limited right now. Cline is still downloading the JDK. But I'm just thinking that if you do it for the user, there's less chance that they do it wrong compared to documenting how to do it and hoping the user follows the docs. It's just an idea I just had. May not be worth anything. |
Which is 12 pages (printed out) of manual steps to follow. The other IDEs take just as much. Almost everyone else on this thread codes Java all the time. They already have everything set up exactly the way they want it. But if you are new to it, it's a real pain in the butt. Again, this is just one data point but when I look at all that compared to asking an AI to "start a python project in a venv" in the AI extension in VSCode I have to ask myself why bother? And yes, there are lots of docs, but frankly, I know about as much about OH and how it works as anyone can know and even I found them hard to follow. If everyone thinks there's no problem, oh well. But I will say that the barrier is high. It's the reason it's taken me a decade before even attempting my first add-on. AI got me over that barrier but not in a way that's sustainable. I actually have a working add-on right now. But I can't maintain it without AI to rebuild the dev environment again. If I can't maintain it, I can't submit it anywhere fo others to use. I also found the skeleton generated to be a bit spare and not super self-explanatory. I had to go back and forth to understand what to do where and in the end just trusted the agent to do it's thing and hope it does it right.
As far as I can tell, Cline using Gemini Flash completely ignored that file. I had to feed it all that information manually, and I'm still not certain that everything documented there is correct in my add-on. At this point all I can say is:
I figured that if there were one download that had everything already configured it would make the code generated by the AIs better and lower the barriers to entry for new developers. Honestly, even after using AI, it's the only part of all of this I still don't have a good grasp on. |
Indeed. But as it did its thing and started making decisions, setting stuff up and writing the code it was clear that it either had not read it or forgotten what was in it. I had to tell it again. 🤷
It certainly would have helped me a lot I think. It still would. |
|
FWIW, I think the Linux Kernel team has defined some decent guidelines for themselves: https://docs.kernel.org/process/coding-assistants.html |
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Hi @openhab/maintainers,
as we have already received a number of bug reports across our GitHub repositories that contained incorrect AI claims, discussion emerged on the community (https://community.openhab.org/t/ai-generated-bug-reports-github-issues-etc) about the introduction of openHAB-wide guidelines on AI-generated contents like bug reports (GitHub issues) and PRs.
Based on @rkoshak's proposal in https://community.openhab.org/t/ai-generated-bug-reports-github-issues-etc/169417/3, I have the following proposal:
Please share your thoughts on my proposal.
Also inviting @Nadahar to the discussion.
Best,
Florian
All reactions