Principle:AI Builder Club Skills Regression Sweep
| Knowledge Sources | |
|---|---|
| Domains | Testing, Verification |
| Last Updated | 2026-10-24 00:00 GMT |
Overview
A methodology for running codified objective checks (type-check, lint, unit, e2e) as a post-verification regression gate, with triage-before-fix discipline that classifies failures before weakening assertions.
Description
The regression sweep is the objective counterpart to subjective agentic verification. After the verifier confirms the task works, the main agent runs a codified set of checks (e.g. pnpm typecheck && pnpm lint && pnpm test && pnpm e2e). The key discipline is triage before fixing: classify each failure as real bug (product broke → fix the code), stale test (flow intentionally changed → update the test), or flaky/env (stack down, timing, rate limit → fix robustness). The cardinal rule: never weaken or delete an assertion just to go green — loosening is only correct when the intended contract changed, confirmed from the diff, not assumed. If a fix changes task behavior, re-verify the task (return to the verifier loop).
Usage
Run after subjective verification passes. The sweep is run by the main agent (not the verifier) because pass/fail is objective and the agent needs the error messages to fix issues directly.
Theoretical Basis
The principle rests on the distinction between objective and subjective verification: objective checks have deterministic pass/fail (type-check, lint), while subjective verification requires judgment (does the feature work for a user?). Mixing them degrades both — the agent might rubber-stamp a broken feature because the linter passed, or weaken a test to fix a subjective concern.
# Abstract procedure:
def regression_sweep():
results = {}
for check in [typecheck, lint, unit_test, e2e]:
results[check.name] = check.run()
for name, result in results.items():
if result.failed:
classification = triage(result) # real_bug | stale_test | flaky_env
if classification == "real_bug":
fix_code(result.error)
elif classification == "stale_test":
update_test(result.error)
else:
fix_env(result.error)
# Never: weaken_assertion(result)
if any_fix_changed_behavior():
re_verify_task() # back to subjective verifier