Quality debt is a quality gap with a continuing cost or risk. Analysis should identify the item and its origin, show the observed effect, and compare repayment with containment or an explicitly accepted risk. Old work is not automatically debt, and age alone is not a priority.

Separate debt from nearby issues

Classify each item before estimating its “interest.” A product defect, an unreliable test asset, a temporary exception, and missing evidence require different actions.

Record typeWhat to captureBoundary
Active product defectObserved behavior, affected users, source, and current controlsTrack the defect itself; do not relabel it as test debt
Test or architecture debtAsset, origin, recurring effort or exposure, age, and dependenciesShow the evidence that the gap keeps costing the team
Temporary exceptionAuthorized scope, owner, reason, controls, and expiryAcceptance needs authority and a review date
Evidence gapMissing or stale data needed to assess an itemKeep the conclusion unassessed rather than treating absence as proof

A ticket, old test, or unfinished task is not enough to establish debt. The source Skill asks for the item, origin, impact, age, priority, ownership, and paydown tradeoff.

Measure the ongoing effect

Show how the gap compounds using observed maintenance effort, exposure, or detection delay. For example, reruns and triage may consume time, but a monetary estimate needs a sourced rate. If frequency or cost data are missing, use a qualitative or conditional range and state what evidence would narrow it.

Rank by business impact, exposure, detectability, dependencies, and repayment effort or benefit. Age is one signal among these. A newer gap with serious exposure can outrank an older, low-impact item.

Audit the evidence

Before assigning a priority, check evidence completeness, credibility, recency, and comparability. Record known, missing, conflicting, stale, out_of_scope, and assumptions. Confirm that evidence covers a comparable time period, the relevant build, and the asset being discussed.

  • known: cite the issue, run, incident, effort record, or control that supports the claim.
  • missing: request the smallest log, time window, impact source, or ownership detail needed.
  • conflicting: preserve both accounts of cause or impact until an owner resolves them.
  • stale: keep older history but do not present it as current rate or control status.
  • out_of_scope: identify related product defects or release choices excluded from this pass.
  • assumptions: state the validation that would keep the provisional ranking in place.

Separate facts, evidence-backed inferences, candidate recommendations, and Human decisions. Do not convert correlation between a flaky suite and escaped defects into a confirmed cause.

Worked example: rank by ongoing risk, not age

The source Skill includes a sanitized synthetic fixture. Its items and decisions are examples, not real project records or business approvals.

ItemSupplied evidenceFixture decision
Q-1A 180-day-old duplicate helper costs 1 hour per month and has no high-risk protection gapLOWER_PRIORITY; age alone does not outrank current impact
Q-2A one-day-old refund test mocks the subject, missed a duplicate debit yesterday, and still leaves loss exposureHIGHER_PRIORITY; the newer item has greater stated exposure, but the mock is not proven to be the cause
Q-3A confirmed production duplicate-debit defect remains unfixedPRODUCT_DEFECT; track it as an active defect, not test debt
Q-4A helper-refactor ticket is closed, but there is no behavior-regression or maintenance-impact evidenceNOT_CLOSED; the ticket alone does not show that the debt effect is gone
Q-5Refactored code, an independent regression, a maintenance sample, and owner acceptance are recordedCLOSED; the fixture contains the required closure evidence

QDA-01 candidate: assess the refund-test gap

Finding fieldExample record
Finding fieldExample record
------
Object and sourceQ-2, the refund test described in the sanitized fixture; no live test ID or repository history is supplied
Trigger and concernThe test mocks its subject, while the fixture reports a missed duplicate debit and continuing loss exposure. This warrants checking the test boundary; it does not establish that the mock caused the miss.
Evidence stateknown for the synthetic fixture; live test history, defect linkage, and production scope remain UNASSESSED
Impact, priority, and ownerHIGHER_PRIORITY relative to Q-1 in the fixture. The live owner and impact rubric are unknown; identify the responsible test owner before ranking project work.
Validation and stop conditionCompare the test definition, execution history, and duplicate-debit evidence over an agreed window. If an active production defect is confirmed, stop the debt ranking and route it through the product-defect or incident process.
Close conditionChange the relevant asset, independently check the intended behavior, show that the recurring exposure or detection gap is removed, and record accountable acceptance.

This example keeps the test gap separate from the active product defect. Any accepted residual risk needs an authorized owner and an expiry or review date.

Choose repayment, containment, or acceptance

For each item, compare the smallest repayment action with containment, monitoring, or a time-bounded acceptance. Record dependencies, owner, target date, residual risk, and the evidence that will show the effect changed.

OptionWhen it fitsRecord and exit condition
RepayThe ongoing cost or risk justifies the repair effortName the asset to change, an independent behavior check, evidence that the effect changed, and the accepting owner
ContainRepayment is not feasible soon, but exposure or impact can be limitedRecord containment scope, compensating controls, monitoring signal, owner, and review date; define escalation if the control fails
AcceptAn authorized owner chooses to carry the residual risk for a bounded scopeState the reason, scope, compensating controls, residual risk, approver, and expiry or review date; renewal requires a new approval

A debt item is not repaid when a ticket closes or a document is written. The source contract requires a changed asset, an independent check of the intended behavior, evidence that the debt effect is gone, and accountable acceptance. If those conditions are not met, keep it open or record an authorized exception.

Put debt treatment inside the quality loop

Quality debt treatment loop: record and rank sourced debt, choose repayment, containment, or time-bounded acceptance, apply and verify treatment where needed, and carry unresolved impact forward

AI-generated tests can suggest missing cases, but generation alone does not repay debt. Review and deduplicate candidates, connect accepted tests to the affected requirement, execute them, then check independently that the original debt effect has changed. Feed escapes, maintenance effort, detection delay, and unresolved evidence back into the next review.

Prepare a reviewable record

Provide the item identifier, origin evidence, impact and controls, age, comparable observation period, effort or exposure data, dependencies, and repayment options. Mark each amount and rate as observed, estimated, or unknown. Keep current defects and decisions outside the debt record unless their relationship is sourced. For CSV, JSON, or ticket output, agree the schema, enums, required fields, and evidence sources first.

Common mistakes

  1. Calling every old test a debt item.
  2. Ranking by age while ignoring exposure, detectability, and repayment cost.
  3. Assigning a root cause from correlation.
  4. Closing the ticket without evidence that the debt effect disappeared.

Best practices

  • Separate active product defects, test or architecture debt, temporary exceptions, and evidence gaps before ranking.
  • Estimate ongoing cost or risk from observed effort, exposure, or detection delay. Without a sourced rate, keep the estimate qualitative or conditional.
  • Rank by impact, exposure, detectability, dependencies, and repayment effort or benefit. Use age as one signal.
  • Close debt only after the asset changes, an independent check passes, the ongoing effect is gone, and an accountable owner accepts the result.

First use: assess one debt item

  1. Pick one test, architecture asset, or exception and identify its source and current control.
  2. Provide a comparable observation period, evidence of impact or effort, age, dependencies, and possible repayment actions.
  3. Ask the Skill to classify the item, state what is known or missing, and name the smallest validation step. Keep the priority unscored if impact evidence or an owner is missing.

Install and invoke

npx skills add https://github.com/naodeng/awesome-qa-skills/tree/main/skills/en --skill quality-debt-analysis

Invoke quality-debt-analysis with scoped evidence, comparable time periods, and the asset or exception under review.

FAQ

Can quality debt be accepted?

Yes, when an authorized owner records the impact, controls, residual risk, and an expiry or review date.

How do I show that debt was repaid?

Use the original evidence measure, show the relevant asset changed, independently verify the intended behavior, and confirm the debt effect is gone.

Can an AI-generated test close a debt item?

No. Treat it as a candidate until it is reviewed and run. Closure still needs a changed asset, an independent behavior check, evidence that the debt effect is gone, and accountable acceptance.

References

The Quality Debt Analysis prompt: https://github.com/naodeng/awesome-qa-skills/tree/main/skills/en/testing-types/quality-debt-analysis/prompts/quality-debt-analysis.md defines QDA-## fields, debt classification, priority considerations, and closure evidence. The worked decisions come from its sanitized synthetic fixture: https://github.com/naodeng/awesome-qa-skills/blob/main/skills/en/testing-types/quality-debt-analysis/references/domain-decision-example.md. Source directory: https://github.com/naodeng/awesome-qa-skills/tree/main/skills/en/testing-types/quality-debt-analysis.

More Resources

Share