{
  "source_file": "0930",
  "source_platform": "Dev.to",
  "author": "Debashish Ghosal",
  "title_listed": "AI Wrote Half My Codebase. The Maintenance Bill Showed Up in Month Three.",
  "keywords": "",
  "domain": "大模型算法",
  "content_type": "深度技术解析",
  "is_paid_flag": "否",
  "url": "https://dev.to/debashish_ghosal/ai-wrote-half-my-codebase-the-maintenance-bill-showed-up-in-month-three-lhp",
  "publish_date": "2026-09-15",
  "corpus_stage": "",
  "notes": "",
  "id": "8598776f0e3d",
  "collected_at": "2026-10-02T14:06:00",
  "title": "AI Wrote Half My Codebase. The Maintenance Bill Showed Up in Month Three. - DEV Community",
  "body_markdown": "AI made the first draft free. I treated that as the win. The bill arrived later, not in dollars, in the parts of the system nobody on the team fully understood anymore.\nI like AI coding tools. I use them every day. I've shipped more open-source projects in the last few months than in years prior, and a lot of that is leverage. Scaffolding is faster. Boilerplate is cheaper. First drafts come together in minutes.\nSo this isn't an anti-AI post. It's an accounting post. We've gotten very good at measuring the first draft and very bad at measuring what comes after it, and the after is where the actual cost lives.\nThe ratio that should worry you\nEvery stage of the development cycle used to have roughly proportional cost. You wrote code, you reviewed code, you maintained code, and those costs were in the same order of magnitude. The economics were stable enough that you could reason about them.\nAI broke the ratio. Generation dropped to near zero. Review stayed flat. Maintenance didn't move at all, and maintenance is the longest phase of any codebase's life.\nSo we get a new shape:\nprojects that look extremely productive in week one and increasingly expensive in month three.\nThe \"month three\" isn't one project's stopwatch. It's the pattern I keep seeing across the tools I've shipped this year, and it's slow. No giant outage. Just an accumulation of code that looked more trustworthy than it was, sitting in places that later changes had to work around.\nThe bug that changed how I read AI code\nThe moment that stuck with me wasn't a fire. It was a small bug in a very clean-looking change. The code read well, the tests passed, the comments looked thoughtful. Nothing about it was reckless. But it misread an API response when an optional field was missing. It handled the happy path and missed the absence.\nWe caught it later, after downstream behavior stopped matching what users expected.\nWhat stayed with me: we approved code none of us had really interrogated. I didn't catch it either. And that is the whole problem, because the code looked\nmore\ntrustworthy than it was, which is exactly why it got less scrutiny.\nI wrote about this at the time in\nAI-Assisted Engineering: Faster to Build Isn't Cheaper to Own\n. The reaction told me the feeling is widespread. The METR study from 2025 is the quantitative version: experienced open-source developers using AI tools took\n19% longer\n, even though they believed they were faster. Not because AI is useless, but because it's easy to feel faster when the first draft arrives quickly.\nWhere the bill actually shows up\nOver the last few months I've instrumented four places where the ownership cost lands. None of them are line items on a typical AI ROI dashboard.\n1. Debugging generated code, including your own.\nCauterRule\nexists because repeated agent failures kept coming back. To debug it properly I had to run a 4,768-trajectory field test, and it took a runner hardening change (per-trajectory timeouts, quarantine, token caps) just to get a run that didn't die halfway. That's the shape of the bill: the code was written in days and needed infrastructure to be\nunderstood\n.\n2. Cost that only appears per task, not per call.\nA cheap model call, a failure, a retry, a failure, an escalation. Your dashboard shows $0.001. The task cost $0.053. I built\nai-tierforge\nbecause almost nobody tracks cost\nper completed task\n, and the real-world savings were 44.8% versus sending everything to one model. The number isn't the point. The point is that per-call pricing hid the actual behavior.\n3. Loops that never terminate.\nA generated agent loop with no circuit breaker doesn't fail loudly. It fails expensively and quietly.\nLoopGuard\nis a circuit breaker for agent loops, and the reason it needed 391 tests is that the failure mode is the system doing work forever.\n4. Understanding you outsource before you learn it.\nThis is the one I can't put a number on, and I think it's the biggest. When a model helps someone ship something that looks professional before they've built the habit of questioning architecture and tradeoffs, the missing judgment has to show up somewhere. Usually it shows up in review, as someone else's time.\nThe part I keep coming back to\nIt's tempting to read this as \"AI makes codebases worse.\" That's not what I think. Mixed is the honest word. Teams move faster in some parts of the work and pay more in others.\nWhat concerns me is that the visible metrics got better and the invisible ones got worse. More PRs, faster demos, more movement. Those are real signals, but they don't tell you whether understanding kept pace, whether review quality held, or whether you pulled future maintenance pain into a prettier present.\nThere's also a second-order effect I keep thinking about. If the model writes the first draft, then the\nreasoning\nthat used to happen while writing now has to happen somewhere else, or it doesn't happen at all. That's a process design choice, not a tooling choice, and most teams haven't made it explicitly.\nWhat I changed\nNot \"use less AI.\" I changed where the human attention goes.\nPush more into automation.\nHumans don't scale attention linearly once volume rises. Deterministic gates don't get tired.\nReview for reasoning, not cosmetics.\n\"Do we understand why this works, what it assumes, and how it fails?\" replaces \"does this look clean.\"\nAsk for explanation earlier.\nIf AI can generate a decent draft, then part of the job is making sure judgment still gets trained on purpose, especially for junior engineers.\nTrack ownership, not just output.\nThe question isn't how fast we shipped. It's how expensive the next change will be.\nI didn't get this right immediately. Some of it only became obvious after the review load got heavier and I realized I was treating symptoms instead of changing the workflow.\nThe honest limitation\nI'm describing a pattern from my own projects. I don't have a clean controlled experiment proving that AI-assisted code costs more to own, and I'd be suspicious of anyone who claims they do. The METR result is a hint, not a verdict. Code quality depends on teams, domains, and how the tool is used.\nBut I don't need a controlled experiment to say this:\nif your definition of \"faster\" stops at the merge, you're measuring the cheap half of the lifecycle.\nThe question I actually care about\nEvery team I talk to is measuring generation velocity. Almost none are measuring ownership cost. What would change if you did?\nSo have you felt the maintenance bill yet, and where did it show up?\nI'm especially curious whether it landed in review time, in debugging, or in the parts of the system that got harder to change.\nRepo:\nCauterRule\n·\n4,768-run field test\n·\nai-tierforge\n·\nai-loopguard\nPrior posts:\nAI-Assisted Engineering: Faster to Build Isn't Cheaper to Own\n·\nAI Can Write the First Draft. It Still Cannot Build Judgment.",
  "metadata": {
    "title": "AI Wrote Half My Codebase. The Maintenance Bill Showed Up in Month Three. - DEV Community",
    "description": "AI made the first draft free. I treated that as the win. The bill arrived later, not in dollars, in... Tagged with ai, agents, llm, maintenance.",
    "keywords": "ai, agents, llm, maintenance, software, coding, development, engineering, inclusive, community",
    "author": null,
    "og:type": "article",
    "og:url": "https://dev.to/debashish_ghosal/ai-wrote-half-my-codebase-the-maintenance-bill-showed-up-in-month-three-lhp",
    "og:title": "AI Wrote Half My Codebase. The Maintenance Bill Showed Up in Month Three.",
    "og:description": "AI made the first draft free. I treated that as the win. The bill arrived later, not in dollars, in...",
    "og:site_name": "DEV Community",
    "og:image": "https://media2.dev.to/dynamic/image/width=1200,height=627,fit=cover,gravity=auto,format=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2Fbo32z79cev48gvd411s9.png",
    "twitter:site": "@thepracticaldev",
    "twitter:creator": "@",
    "twitter:title": "AI Wrote Half My Codebase. The Maintenance Bill Showed Up in Month Three.",
    "twitter:description": "AI made the first draft free. I treated that as the win. The bill arrived later, not in dollars, in...",
    "twitter:card": "summary_large_image",
    "twitter:widgets:new-embed-design": "on",
    "twitter:image:src": "https://media2.dev.to/dynamic/image/width=1200,height=627,fit=cover,gravity=auto,format=auto/https%3A%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Farticles%2Fbo32z79cev48gvd411s9.png"
  },
  "paywall": {
    "listed_paid": false,
    "detected": false,
    "marker": "",
    "public_only": false,
    "policy": "付费/会员内容只保留页面公开可见部分，不绕过付费墙"
  },
  "crawl": {
    "success": true,
    "status_code": 200,
    "error": ""
  },
  "code_blocks": [],
  "images": [],
  "audio": [],
  "videos": [],
  "links": [
    {
      "href": "https://dev.to/debashish_ghosal/ai-assisted-engineering-faster-to-build-isnt-cheaper-to-own-1lh",
      "label": "AI-Assisted Engineering: Faster to Build Isn't Cheaper to Own",
      "type": "a"
    },
    {
      "href": "https://github.com/deghosal-2026/CauterRule",
      "label": "CauterRule",
      "type": "a"
    },
    {
      "href": "https://github.com/deghosal-2026/ai-tierforge",
      "label": "ai-tierforge",
      "type": "a"
    },
    {
      "href": "https://github.com/deghosal-2026/ai-loopguard",
      "label": "LoopGuard",
      "type": "a"
    },
    {
      "href": "https://github.com/deghosal-2026/CauterRule/blob/main/docs/field-test/v0.3.0/FIELD_TEST_REPORT.md",
      "label": "4,768-run field test",
      "type": "a"
    },
    {
      "href": "https://dev.to/debashish_ghosal/faster-prs-weaker-instincts-the-judgment-problem-in-ai-assisted-engineering-4fd8",
      "label": "AI Can Write the First Draft. It Still Cannot Build Judgment.",
      "type": "a"
    }
  ],
  "repair_version": 2,
  "repaired_at": "2026-10-14T10:50:13Z",
  "source_url": "https://dev.to/debashish_ghosal/ai-wrote-half-my-codebase-the-maintenance-bill-showed-up-in-month-three-lhp",
  "papers": [],
  "actual_video_files": [],
  "body_chars": 6863,
  "expected_body_images": 0,
  "discovery_status": "ok",
  "delivery_status": "ok",
  "missing_reason": "",
  "raw_html": "attachments/8598776f0e3d/pages/source.html",
  "local_html": "attachments/8598776f0e3d/pages/article.html",
  "body_base_path": "attachments/8598776f0e3d/pages/",
  "body_markdown_path": "attachments/8598776f0e3d/pages/article.md"
}