I've tried this, aggressively and it still does it for me. I gave up.
I tried this as well. I'm interfacing with Gemini 2.5 using Cursor and I have rules to to limit the comments. It still ends up over-commenting.
I have a feeling this may be a cursor issue, perhaps cursors system prompt asks for comments? Asking in the aistudio UI for code and ending the prompt with "no code comments" has always worked for me
It strips the comments from the code or else it gets the hose again.
I did not, but I'm curious if this would actually work.
Maybe too many comments could be a good metric to check if someone just yolo accepted the result or if they actually checked if it's correct.
I don't have problems with getting lot's of comments in the output, I am just deleting it while reading what it did
another great tell of code reviewers yolo'ing it is that LLM's usually put the full filename path on the output, so if you see a file with the filename / path on the first line, thats prob a llm output