Policy Currency Runbook

For a maintainer or policy analyst keeping canopy’s cited policy values provably current. The tooling is ADR-031 §1; the underlying traceability discipline is ADR-011.

The moving parts

cargo xtask policy audit

Deterministic, blocking. Validates both citation families — jurisdiction (the pack’s citations.toml ↔ jurisdiction.toml) and federal (the federal layer’s citations.toml ↔ the JSON data files): completeness, reverse completeness (orphans), value consistency, staleness, source-pin schema, and the annual indexing windows (the federal layer’s indexing.toml).

cargo xtask policy sync-cache --jurisdiction {j} [--pin]

Clones/pulls the PAMMS source repos into target/policy-cache/{j}/ and records the sync manifest (per-repo HEAD + per-cited-file SHA-256). --pin back-fills source_sha256 onto citations whose source_ref resolves in the cache (format-preserving; idempotent).

cargo xtask policy drift --jurisdiction {j} [--no-sync]

Advisory, never edits values. Re-syncs (unless --no-sync) and compares each committed source_sha256 pin against the current hash of its cited file. Exit 1 on drift; the adr-031-policy-drift CI job is permanently allow_failure: true.

When drift fires

A CHANGED: finding means the upstream manual section changed since the value was last verified — it does not mean the value is wrong. For each drifted source file:

  1. Re-read the section in the policy cache (target/policy-cache/{j}/<source_ref>, anchor in the citation’s section field). The drift report lists every affected citation with its manual_transmittal / effective_date / verified_date context.

  2. If the value changed upstream: update jurisdiction.toml, then the citation (value, effective_date, manual_transmittal, notes), and set verified_date to today.

  3. If the value is unchanged (editorial churn, unrelated edits in the same file): bump the citation’s verified_date to today.

  4. Re-pin: cargo xtask policy sync-cache --jurisdiction {j} --pin — the new hashes commit with your MR, and drift returns to clean.

A MISSING UPSTREAM: finding means the cited file no longer exists in the refreshed cache (moved or deleted upstream): find the section’s new home, update the citation’s source_ref, re-verify, re-pin.

When the audit fires

  • ORPHAN: — a citation targets a key/value that no longer exists. Fix the key, remove the citation, or (only when the value genuinely lives in JDM rule content / service code) allowlist it with a written reason in compliance/adr-031-citation-orphan-allowlist.toml.

  • ALLOWLIST-STALE: — an entry in that orphan allowlist matches no citation (crates/canopy-policy/src/citation.rs, #1168). It is an error, not a warning: restore the citation the entry was written for, or retire the entry.

  • OUT-OF-WINDOW: — an indexed federal family’s newest table predates the current annual window (warning inside the family’s publication grace, error after). Transcribe the new federal tables (FNS COLA / HHS FPL / ACF SMI / CMS-416 instructions) into a new *-{year}.json in the federal layer, cite it, and assign it in indexing.toml if the pattern doesn’t already match. Step-by-step: The annual federal cycle.

  • UNINDEXED: — a new federal data file has no indexing.toml family. Declare its cutover cadence or add it to the static family.

  • MISSING: / MISMATCH: / SCHEMA: — forward completeness, value consistency, and citation-schema findings per ADR-011; fix the cited value or the citation.

  • STALE: (warning) — verified_date older than --max-staleness-days (default 365): re-verify the value against its source and bump the date (re-pin while you’re there). Citations with authority = "fixture" — the synthetic fixtures/config/test-* and fixtures/config/default values — are exempt, because their source is versioned in this repo rather than upstream (#761).

The annual federal cycle

The federal layer’s indexing.toml declares each family’s cutover and grace window, and the audit flags an out-of-window family automatically, so the calendar enforces itself. Four indexed families ship today; everything else belongs to static.

Family Cutover Grace What to do, and when

snap-cola

Oct 1

0 days

FNS publishes the SNAP COLA memo in August, effective at the federal fiscal-year start — publication precedes the cutover, so the family carries no grace (#1839). Stage the three new snap-{allotments,deductions,income-limits}-YYYY.json files before October 1; see How canopy-snap selects a SNAP COLA set.

fpl

Jan 1

90 days

HHS publishes the poverty guidelines in mid-to-late January; programs adopt on publication. Add fpl-YYYY.json and update the three code pins that name the file — services/canopy-medicaid/src/params.rs, services/canopy-reporting/src/reporting/medicaid.rs and services/canopy-wic/src/params.rs. No jurisdiction ruleset references it by year.

smi

Oct 1

30 days

ACF publishes the SMI estimates on the LIHEAP cycle (45 CFR 96.85 — "by October 1 of each year, or by the beginning of the State fiscal year, whichever is later"); the IM lands around April and adoption is mandatory at the federal fiscal-year start. Add the new edition as smi-YYYY.json (its _effective_date = the October 1 it takes effect) before October 1. There is no July federal SMI cycle (#1668). The file carries every state ACF publishes, keyed by FIPS state code, with the 45 CFR 96.85(b) ladder as data (#3279); each adopting pack then adds a cited [caps.smi_adoptions] row giving its state’s adoption date, and canopy-caps switches to the edition on that date (#1669) — no code change, no deploy tied to the date. Procedure: the federal layer’s README.adoc › SMI editions and pack adoption.

cms-416

Oct 1

90 days

CMS-416 EPSDT reporting constants track the federal fiscal year; the instructions update ahead of the reporting cycle.

Gate a new federal file with cargo xtask policy audit --source federal (citation, indexing window, schema — CI job adr-031-federal-audit) and cargo xtask rules check (JDM compile). A table carried forward unchanged because its successor has not published yet is marked PROVISIONAL: in its source_ref, with the replacement issue named in notes.

How canopy-snap selects a SNAP COLA set

canopy-snap discovers every snap-{allotments,deductions,income-limits}-*.json at boot, groups them into complete triples by their _effective_date header, and selects the set in force at each determination’s evaluation date (services/canopy-snap/src/param_sets.rs). A set’s validity is intrinsic: [_effective_date, first-Oct-1-after). Consequences when staging a fiscal year:

  • Drop the three new files beside the old ones — never replace or delete them. Old sets keep replay and audit identity; git is the byte retention (ADR-003).

  • A triple must be complete for its date and its _fiscal_year values must agree, or the service refuses to boot.

  • Each set reads its minimum benefit and homeless shelter deduction from its own files, so the October COLA moves them with the rest (#3229). The earned-income percentage is still duplicated in snap-budgeting-factors.json and must agree — a divergent edit is a boot error, not silently inert (single-sourcing the rest is #1478).

  • After the old set’s October 1 expiry with no successor staged, determinations fail closed (422). CANOPY_SNAP__ALLOW_EXPIRED_PARAM_SET=true is the accountable override (services/canopy-snap/src/config.rs; error-logged per use).

  • A staged set is previewable before its window opens (#1472): restart, read its digest from GET /v1/params/provenance?as_of=<cutover date>, then dry-run a case with target_policy {corpus_hash, params_digest}. The preview is write-free and echoes the resolved window.

The directory’s own conventions — the file index, the citation and indexing model, and the synthetic test-min / test-max fixture blocks — are in the federal layer’s README.adoc, next to the data.

New jurisdictions

A jurisdiction with a git-backed, PAMMS-like manual system gets the full loop (sync → pin → drift) via [policy_source] in its jurisdiction.toml (canopy_policy::source::GitPolicySource). A jurisdiction without one uses type = "manual": citations carry authority = "manual", every resolution answers manual-verification-required (ManualSource), and currency rests on the staleness check + the jurisdiction’s own verification process.

Edit this page · default