You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
feat: lint anchor_drift / anchor_missing — detect staleness from code drift, not age #147
lint currently treats a decision as stale after 30 days (tools/lint.go, staleDecisionThreshold). Age is a weak proxy: a week-old learning can be wrong after one merge, and a year-old one can still be exact. Detect staleness from code drift instead.
Proposal
Depends on the temporal-validity fields (as_of, evidence).
anchor_missing — a cited path doesn't exist at as_of, or a <repo>#<n> citation doesn't resolve.
anchor_drift — a cited path changed between as_of and HEAD → mark the entry stale-unverified, including validated entries (demotion of validity is automatic; tier promotion stays human).
Keep the age check as a secondary hint, not the primary signal.
Entirely deterministic: git + path existence, no model.
Evidence
In the KB effort this was the "existence pre-pass": it resolved every path and PR/issue citation at the pins and queued exactly the claims whose cited files had changed in the window (4 paths → 6 claims) for deep re-verification. It also found that a third of the #N citations were issues, not PRs, in the shared number space.
Related existing work
Content sanitizer (sanitize/): sanitize.ContentDrift already flags page content-hash changes between index cycles. That is drift in indexed content; this issue is drift in the code a claim cites. Complementary — consider reusing its hashing and Finding plumbing, and name the lint kinds so the two aren't confused.
Spec 013 (knowledge-compile) defines the 30-day stale_decision check. This issue demotes it to a secondary hint, which changes spec-defined behavior; the spec should be amended alongside.
Acceptance
lint reports anchor_missing / anchor_drift with the entry identity, the anchor, and the commit range.
lint --fix (or an equivalent) can set validity: stale-unverified; it never changes tier or deletes content.
Activity
feat: lint anchor_drift and anchor_missing from code drift (unbound-f…
docs(openspec): add lint-anchor-drift change (unbound-force#147)
feat: lint anchor_drift and anchor_missing from code drift (unbound-f…
fix(tools): harden anchor fix against untrusted input (unbound-force#147
docs(openspec): add lint-anchor-drift change (unbound-force#147)
feat: lint anchor_drift and anchor_missing from code drift (unbound-f…
fix(tools): harden anchor fix against untrusted input (unbound-force#147
fix(tools): address review on anchor checks (unbound-force#147)
docs: sync anchor-check docs after review (unbound-force#147)
docs(openspec): add lint-anchor-drift change (unbound-force#147)
feat: lint anchor_drift and anchor_missing from code drift (unbound-f…
fix(tools): harden anchor fix against untrusted input (unbound-force#147
fix(tools): address review on anchor checks (unbound-force#147)
3 remaining items
docs(openspec): add lint-anchor-drift change (unbound-force#147)
feat: lint anchor_drift and anchor_missing from code drift (unbound-f…
fix(tools): harden anchor fix against untrusted input (unbound-force#147
fix(tools): address review on anchor checks (unbound-force#147)
docs: sync anchor-check docs after review (unbound-force#147)
fix(tools): address round-2 review on anchor checks (unbound-force#147)
docs: sync anchor-check docs after round-2 review (unbound-force#147)
docs(openspec): add lint-anchor-drift change (#147)
feat: lint anchor_drift and anchor_missing from code drift (#147)
fix(tools): harden anchor fix against untrusted input (#147)
fix(tools): address review on anchor checks (#147)
docs: sync anchor-check docs after review (#147)
fix(tools): address round-2 review on anchor checks (#147)
docs: sync anchor-check docs after round-2 review (#147)