arXiv:2610.41276cs.SEOct 2026

Manuscript Offprint

arXiv:2610.41276

Architectural Debt Enforcement under Incomplete Observation: A Controlled Study of Ratchets and Evidence Qualification

Zhiheng Zhang

Abstract

Architectural debt gates must distinguish an allowed change from an incompletely observed one. We study a decision contract separating observation qualification, prohibited relation identity, inherited debt and authorized baseline updates. Across 240 fixed files from four repositories, the current observer and programmatic reference jointly qualify 166 files (69.17%), all with exact reference-relative edge agreement; 74 remain reference-UNKNOWN. Coverage varies from 13/60 to 59/60 by repository. On 480 constructed state scenarios sharing 60 source anchors, both the candidate ratchet and mature dependency-cruiser baseline match every expected outcome, whereas static and count-only baselines match 420 and 360. These results do not establish candidate superiority. Preserved failures include nine additional false-PASS probes and 120 unqualified full-tree timing attempts. A subsequent generic binding layer rejects 54 specified mismatches, accepts 54 current controls and permits legal repetition. Two bounded package scopes support 40 scenarios and 48 fresh-process functional checks; their costs remain tied to the measured implementations. Diagnostics explain residual uncertainty through type/runtime relations, installation context and generated-artifact provenance. TypeScript 5.9.3 and 6.0.2 yield identical outputs on ten paired emission witnesses, but neither that agreement nor verified release provenance changes the frozen UNKNOWN labels. The contribution is a controlled account of evidence-qualified enforcement and its limits, not language completeness, natural maintenance effectiveness or a new shrinking-baseline algorithm.

1 Introduction

A dependency gate can prevent a prohibited architectural relation only if its observation represents the relevant source. An empty violation list can mean that no forbidden relation exists, but also that a scan omitted a file, a module expression exceeded the observer's model, or evidence came from a stale source state. Existing debt creates another distinction: preserving its count does not preserve its identity. Removing one violation while introducing another can keep the total unchanged, and a static permission for an inherited relation can allow that relation to return after repair.

Shrinking known-violation baselines already address the latter state problem in mature tools. The unresolved premise is whether a particular decision is backed by a qualified, current observation under an authorized policy and debt state. This premise is easy to hide when evaluation reports agreement only on files that its reference can resolve. In our fixed census, perfect agreement within the jointly qualified subset coexists with 74 reference-UNKNOWN files. The main empirical question is therefore what those decisions establish and what remains outside their evidence boundary.

We report a controlled mechanism study with three contributions. First, we make the decision contract explicit: observation qualification, relation identity, debt retirement and state authority have distinct roles. Second, we retain and analyze observation and evidence-binding failures, and evaluate a generic current-context layer that can wrap a mature dependency tool. Third, we trace residual uncertainty within fixed source snapshots to specific type/runtime, installation and artifact-context questions. This diagnosis is empirical and bounded; it is not a universal taxonomy of resolver failures.

The paper organizes the evidence around four reporting questions:

  1. RQ1: What coverage and reference-relative agreement are established, and how do they vary across the sampled repositories?

  2. RQ2: Which constructed changes distinguish count, static-identity and shrinking-debt semantics, including mature-tool alternatives?

  3. RQ3: When do missing or mismatched inputs fail qualification, and what does generic current-context binding establish?

  4. RQ4: What successful operation and cost are demonstrated on explicitly bounded, functionally checked scopes?

Coding agents motivate the need for protected governance, but no natural agent trajectory or productivity outcome is measured. Controlled scenarios, repeated source anchors and post-exposure diagnostics are identified as such. A negative result remains part of the study even when a later engineering repair succeeds.