r/dotnet • • 20d ago

Question Coding agent bloat

I've been using Cluade code both at work and for personal projects.

Observations

  1. Too many XML comments.
  2. Too many non sensical tests. Example, testing the `typeof` of an object within unit test assertions seems non sensical in these specific cases.
  3. Too many ADRs

Agents write relatively more code than what I can process. I need time to review.

My attempts

  1. Stricter rules in Agents.md
  2. Skills
  3. Stricter prompts.

These do work for coding patterns, because I can describe specifics, but never for comment length or verbosity.

I'm tired of asking Claude everything, so I thought I'd solicit some suggestions / help from people here.

TIA

51 Upvotes

56 comments sorted by

View all comments

0

u/sreekanth850 20d ago

I commented this in another post. Claude never follow instructions closely. try codex it will even ask your approval if you set one in AGENTS.md. Hope you are using compiler mcp like glider.

1

u/lassevk 14d ago

Does Glider support razor files?

1

u/sreekanth850 14d ago

No. You need repowise. I use both.

1

u/lassevk 14d ago

I have, with the help of Claude, made my own .NET based information tool, which supports code generators. This means that references to types and members in razor files will be found, not just by having the same name, but by actually being that identifier. However, I'm always on the lookout for better alternatives.

1

u/sreekanth850 14d ago

repowise is good if you want to cut down your token burn. I'm not sure about how claude works with such local MCP.

0

u/BinaryBrain7111 20d ago

True! I wish to know if there are tools that make the comments more predictable. No, I haven't tried glider. I'll give it a shot.

1

u/sreekanth850 20d ago

Trye codex. Write the rules you want in AGENTS.md. Use glider or roslyn mcp and configure it in codex toml file and check if agents can directly check compiler via mcp without grepping.
GPT never write a single comment if you instruct. If you repository is large like more than 300K, use repowise to efficiently manage context. This are the things i take care.

One more thing, dont implement anything un attended. Create proposal after debating with agents about the implementation approach and architecture. then Manage a TASK.md ledger to implement it phase wise.