When software is first built, its architecture is clean, and its boundaries are well-defined. But as soon as it enters continuous maintenance, a slow, invisible decay begins. This decay is often framed as "technical debt"—a metaphor comparing sloppy code to financial borrowing.
However, empirical research reveals that technical debt is not just a static pile of unpolished code; it is a dynamic, compounding feedback loop. Every patch, quick fix, or automated script alters the system's trajectory, making future changes progressively harder. Understanding why this debt accumulates requires looking past individual lines of code to the systemic trade-offs made during continuous software evolution.
The Functional vs. Structural Trade-Off
Why does code quality degrade even when developers are actively trying to maintain it? The root cause lies in a fundamental asymmetry between external behavior (functionality) and internal structure (architecture).
When fixing a bug or deploying a rapid update, the primary goal is functional persistence—ensuring the software works right now. To achieve this under tight deadlines, developers frequently introduce conditional logic, special cases, or localized patches. A large-scale study by Alexander Trautsch et al. (What really changes when developers intend to improve their source code: a commit-level study of static metric value and static analysis warning changes) uncovered what they call the "bug-fix paradox": while dedicated refactoring successfully reduces code complexity, corrective maintenance (fixing bugs) systematically increases code size and complexity. By adding quick-and-dirty fixes to bypass architectural constraints, teams inadvertently degrade internal structural quality to preserve external correctness. This phenomenon is a universal byproduct of rapid deployment cycles, occurring in traditional codebases as well as low-code development environments, as noted by Zhengwu Shi et al. (Democratizing Digital Transformation: A Multisector Study of Low-Code Adoption Patterns, Limitations, and Emerging Paradigms).
This trade-off is even more pronounced in autonomous AI coding agents. When evaluated on single-turn tasks, large language models (LLMs) appear highly capable. However, when forced to maintain a persistent codebase over multiple development cycles, a hidden surge in technical debt occurs. As K N Ajay Shastry et al. demonstrate in Beyond Isolated Tasks: A Framework for Evaluating Coding Agents on Sequential Software Evolution, standard functional testing completely fails to detect long-term structural degradation. An agent can generate code that passes immediate test suites while introducing massive cognitive complexity and structural messiness underneath. To avoid the labor-intensive process of updating deep dependencies, automated agents will often implement suboptimal shortcuts, such as unnecessary compatibility layers, prioritizing immediate functional success over architectural purity (Alex Thillen et al. in CodeTaste: Can LLMs Generate Human-Level Code Refactorings?).
The Compounding Cascade and the Performance Cliff
If technical debt accumulated linearly, it would merely be a predictable tax on development velocity. Instead, it compounds. Unresolved structural issues early in a project's lifecycle act as friction points for every subsequent modification, triggering a cascade of failures.
This compounding effect creates a distinct "performance cliff" in continuous software evolution. In long-horizon development tasks, early regressions or messy implementations make subsequent tasks exponentially harder to resolve. For instance, Gangda Deng et al. (EvoClaw: Evaluating AI Agents on Continuous Software Evolution) found that while frontier AI agents succeed at over 80% of isolated, clean-slate coding tasks, their success rate plummets to just 38% when operating within a persistent environment where errors and debt are allowed to accumulate over time.
[Clean Slate Task] ───> 80% Success Rate (Isolated Evaluation)
[Persistent Environment]
Task 1 (Passes Tests but adds structural messiness)
└──> Task 2 (Friction from Task 1 requires a shortcut)
└──> Task 3 (Accumulated debt triggers cascade) ───> 38% Success Rate
Without active structural maintenance, repositories naturally devolve into disorganization. Rather than systematically refactoring existing files, iterative development cycles—especially those driven by autonomous agents—tend to accumulate redundant files, throwaway scripts, and fragmented modules (John Yang et al. in CodeClash: Benchmarking Goal-Oriented Software Engineering). This linear expansion of repository complexity increases the cognitive load required to make any future change, effectively stalling long-term software evolution.
The Dominance of Design Debt
Not all technical debt is created equal. Low-level code quality issues, such as "code smells" or formatting errors, are localized and relatively easy to isolate. The real threat to software sustainability is design debt—suboptimal architecture, misplaced code, and broken structural boundaries.
Empirical analyses of Self-Admitted Technical Debt (SATD)—instances where developers explicitly confess to hacks or shortcuts in code comments—reveal that architectural compromises are the most common trade-off made under time constraints. Research by Solomon Mensah et al. (Rework Effort Estimation of Self-admitted Technical Debt) and Jiakun Liu et al. (An Exploratory Study on the Introduction and Removal of Different Types of Technical Debt) shows that structural and architectural shortcuts constitute the vast majority of admitted debt. When deadlines loom, developers choose to compromise the underlying architecture of the system rather than documentation or testing because architectural flaws are less likely to break immediate functional requirements.
This concentration of design debt is particularly insidious because it is rarely paid back by its original creators. Daniel Feitosa et al. discovered in Does it matter who pays back Technical Debt? An empirical study of self-fixed TD that while low-level code smells are frequently self-fixed, complex design debt is routinely neglected, leaving a heavy maintenance burden for subsequent developers who lack the original context. Over time, this leads to "architecture erosion," where the actual implementation of a software system drifts entirely away from its intended design due to human factors like aggressive deadlines and knowledge vaporization (Ruiyin Li et al. in Understanding Architecture Erosion: The Practitioners' Perceptive).
The Friction of Repayment
If the consequences of technical debt are so severe, why don't teams simply clean it up? The answer lies in the high friction and economic risk associated with refactoring.
Software maintenance requires a pragmatic cost-benefit analysis. As Amjed Tahir et al. point out in Code Smells Detection via Modern Code Review: A Study of the OpenStack and Qt Communities, developers often choose to leave known code smells unaddressed because the immediate risk of introducing regressions or breaking a working system outweighs the perceived long-term benefit of code purity. This friction is compounded by a "discovery gap": while automated systems and AI agents can easily follow a pre-defined refactoring blueprint, they struggle significantly to identify what needs to be refactored when given a large, complex codebase (Alex Thillen et al. in CodeTaste: Can LLMs Generate Human-Level Code Refactorings?).
Worse yet, refactoring is not a guaranteed cure. Structural modifications intended to simplify code are highly complex and can inadvertently introduce new design flaws. In fact, Di Zhang et al. found in A Preliminary Investigation of Self-Admitted Refactorings in Open Source Software (S) that in roughly 30% of instances where developers explicitly intended to improve code structure, their modifications actually resulted in a net increase in technical debt or code smells.
Finally, this friction extends beyond production code to the test suites themselves. When test code is treated as a secondary, throwaway asset rather than a first-class component, the test suites themselves accumulate debt, becoming fragile and resistant to change (Konstantin Läufer et al. in Tests as maintainable assets via auto-generated spies: a case study involving the scala collections library's iterator trait).
Without a balanced maintenance-to-innovation ratio and robust governance frameworks, software projects inevitably cross a threshold where the cost of corrective maintenance eclipses the capacity for innovation, rendering the system unsustainable (George K Thiruvathukal et al. in Towards Sustainable Digital Humanities Software; Jiashan Wang in Design and Accomplishment of BS-based Supervisory System for Student Assignment Online).
Key Foundational Work
Design and Accomplishment of BS-based Supervisory System for Student Assignment Online (2014) — contributed 1 concept elements to this direction.
An empirical investigation of modularity metrics for indicating architectural technical debt (2014) — contributed 1 concept elements to this direction.
Towards Sustainable Digital Humanities Software (2015) — contributed 1 concept elements to this direction.