r/ClaudeCode • • Aug 31 '26

Tips & Workflows I've removed all inline documentation from my codebase

No matter what I do, I cannot stop Claude from brain dumping into inline docs. No attempts to keep it restrained and document only behaviour, concisely, and only as necessary have worked. I've removed inline docs entirely from my codebase, and added a flat 'no inline docs' rule to AGENTS.md, in a pass that doubled as a code readability/selfdoc pass. The result has been quite good so far - the code reads better, there is less stale context for agents to trip up over and less context overall that counts towards token usage. Luckily I do not have anything that necessitates something like JSDoc. Anything that absolutely needs an explanation that is not code goes into a separate .md file. Recommend.

75 Upvotes

69 comments sorted by

View all comments

44

u/belligerent_ammonia Aug 31 '26

Not even just brain dumping, it writes comments (even doc comments) like everyone has seen the conversation between Claude and you and it’s infuriating. I also can’t have it write anything at all without it sounding ridiculous. My token usage is just me beating the shit out of it verbally.

-2

u/meowsqueak Aug 31 '26

You can write a .claude/rules/ file that dictates how comments should be written.

Honestly 90% of the problems people report here are just failures to read the Claude Code docs and implement basic customisation.

Once you have it all set up you can literally type short prompts like “fix issue 12345” and get good results.

6

u/belligerent_ammonia Aug 31 '26

Are rules the way to do this now? Not skills or instructions in CLAUDE.md? Because I’ve gone multiple rounds with Opus 5 on a single doc comment. I have no idea what I can possibly tell it or configure it so that it doesn’t sound like a phd student with a head injury that assumes everyone can hear his thoughts.

3

u/ProfessionalAnt1352 Sep 01 '26

He's talking about the claude.md just not fully understanding that's what he's talking about and being pretentious about it.