Live data from Hacker News

An AI coding agent, used to write code, needs to reduce your maintenance costs

jamesshore.com

41–50 of 126 posts

Re: An AI coding agent, used to write code, needs to reduce your maintenance costs

#41
> Your crowd might tell you that, for each month you spend writing code, you’ll spend... 10 days on maintenance in the first year; and 5 days on maintenance each year after that

Someone is an optimist! I'd estimate those significantly higher, and even worse if you are in a field that has to do any sort of SOC/HIPAA/GDPR audit

Re: An AI coding agent, used to write code, needs to reduce your maintenance costs

#42
post #40

Insightful. Agree with this take. Unfortunately, maintainability is simply bucketed as a "non-functional" requirement. Maintainability (and similar NFRs) should actually be considered what preserves and enables the delivery of future functional requirements -- in contrast to framing non-functional requirements as simply "how" the software must do what it does vs. the "what"/functional requirements that "actually matt…

I've found the first, and most important, step for any team or organisation to eliminate concerns with NFRs, "tech debt", and whatever else it may be called, is to stop giving it a name. I'm being completely serious. By giving it some kind of distinct name, you are giving license to it being ring-fenced and de-prioritised by someone who doesn't (but, arguably, probably should) know better. Quality matters. It hits yo…

Name it "not done yet." But, yes, very keen observation here.

Re: An AI coding agent, used to write code, needs to reduce your maintenance costs

#43
post #4

Same with code reviews. I wonder if AI could make code reviews more presentable. for example, with human code reviews, developers learn quickly not to visually change code like reflowing code or comments, changing indent (where the tools can't suppress it), moving functions around or removing lines or other spurious changes. And don't refactor code needlessly. also, could break reviews up into two reviews - functiona…

Do any refactorings in separate reviews, and say things like "REFACTOR_ONLY:", with a rule that none of the code changes behavior.

That makes reviews a lot easier. The review starts from "nothing should be changing" and then reviewers can pattern match on that.

Otherwise, the reviewer is re-evaluating every line of code to make sure nothing has changed. That's really hard to do properly.

The version control systems I've worked with have allowed queues of changes, each one reviewed independently. As I'm developing, if I need a refactor, I go up a commit, refactor, send out for review, rebase my in progress work and continue.

I send out a continual stream of "CLEANUP:" "REFACTOR_ONLY:", and similar changes with the final change being a lot smaller than a big monster of a change.

Your reviewers will appreciate the effort.

Plays the metric game (if you're working in that type of org) without being evil too.

Re: An AI coding agent, used to write code, needs to reduce your maintenance costs

#46

Yeah, but to be honest, I sometimes just tell Claude to cleanup / refactor stuff; it finds a lot of things, discusses it with me and I approve the plan, and it churns away my tokens for some time. I do this once in a while, and I've been doing this for over 6 months and I don't feel like my development has significantly slowed down. Yeah my token usage is more for sure, but my codebase also is, so I'm not worried abo…

I'm getting downvotes for this. Why exactly?

Re: An AI coding agent, used to write code, needs to reduce your maintenance costs

#47
One thing I like about framing this as maintenance cost is that it moves the measurement boundary. The usual AI coding metric is something like accepted diff per hour, but the more interesting unit is probably future decisions created per hour.

An agent can reduce typing while increasing the number of things nobody really owns later: rationale, invariants, tradeoffs, half-meaningful tests, files that changed because they were nearby, etc. The PR can pass and still leave the team with more intent to rediscover.

The useful agent workflows I keep coming back to are less about "write more code" and more about making every change come with a maintenance handle: what invariant changed, what should fail if this is wrong, what files should not have changed, what rollback looks like. It feels slower in the moment, but it gives future-you something to grab onto.

Re: An AI coding agent, used to write code, needs to reduce your maintenance costs

#48
This could have been a good piece of writing if the author chose not to be so smugly overconfident in their belief and show real evidence to support their claim. Mentioning the front page of HN as your source is glib and immediately made me doubt the conclusions. I was interested to see what work the author put into researching this but apparently they didn’t do any work at all.

When an LLM provides you with an overconfident piece of writing with no sources to back it up, what do you do?

Re: An AI coding agent, used to write code, needs to reduce your maintenance costs

#49

This could have been a good piece of writing if the author chose not to be so smugly overconfident in their belief and show real evidence to support their claim. Mentioning the front page of HN as your source is glib and immediately made me doubt the conclusions. I was interested to see what work the author put into researching this but apparently they didn’t do any work at all. When an LLM provides you with an overc…

> When an LLM provides you with an overconfident piece of writing with no sources to back it up, what do you do?

You draw made up lines on made up plots and call it evidence, obviously.

Re: An AI coding agent, used to write code, needs to reduce your maintenance costs

#50
post #3

Earlier quoted context omitted.

This will probably be how things will work in future: devs will shift to specifying features which will be validate through tests. The AI will then be middle layer that will iterate until tests pass. Layer 1: Specs (Humans) Layer 2: Code (AI mostly) Layer 3: Tests (AI + human checks).

What a boring fucking future.

Which to me is why it’s so important to build cooler and crazier shit. A web app to facilitate some business process was always boring, but at least you got to code. Now it’s just boring. The thing I’m building right now is pretty wild, involving computer vision, robotics, and surgery. It’s super complex and without AI, the development would have bankrupted us. But because of ai, we did it and the product is going to FDA this year.
Post reply on HN