Plan: Scenario Inventory & Human-Fidelity E2E (epic &61)

Status: In progress — MR1–MR3 and MR5–MR7 shipped; MR4’s journey family is still growing under epic &61
Epic: &61 (parent &58)

NOTE

Implements ADR-031 §3 for epic &61 (parent &58), under the corpus architecture ratified by ADR-032: an engine corpus (synthetic test-min/test-max fixtures, universal + election-dependent scenarios, canopy CI) and per-jurisdiction conformance packs (Georgia first — the UAT suite and onboarding template). Consumes &60’s action catalogue (scenario steps reference catalogued actions; state-manual rows feed conformance scenarios) and &59’s currency assurance (conformance journeys assert against current values). Grounding below is code-verified (2026-06-09; ADR-032 amendments 2026-06-10). Issues are cut from the Status rows per ADR-013 once this plan lands.

Status

MR Scope Status

MR1

Inventory schema + the cargo xtask scenarios audit gate (canopy_policy::scenario; data under compliance/scenario-inventory/, elections resolved against compliance/federal-options/)

Done (2026-06-11) — !590

MR2

SNAP scenario inventory — engine rows + the Georgia conformance seed, runnability-mapped

Done (2026-06-11) — !591

MR3

TANF / Medicaid / CHIP / CAPS / WIC inventories; journey-tier triage filed as #849–#854; the dangling-binding check made blocking

Done (2026-06-11) — !592

MR4

Journey harness pattern — the journey-* spec family and Playwright project, built on ADR-033 step-primitives with relational assertions; work-list #849–#854

In progress — slices 1–7 landed 2026-06-14; further journeys land as their blocked_by endpoint issues unfence (the &61 burn order)

MR5

Synthetic engine fixtures rulesets/test-min/ + rulesets/test-max/ (design authority: the fixture-design appendix)

Done (2026-08-27) — !1259

MR6

Integration-test jurisdiction hygiene — canopy_test_lib::test_jurisdiction() replaces the georgia literals

Done (2026-08-27) — !1258

MR7

Journey walkthrough pairing gate + the UI-gap backlog (#972, ADR-031 Amendment 1)

Done (2026-07-06) — !765

The per-MR specification and delivery notes live in the merge requests and CHANGELOG.adoc; the live coverage count is the output of cargo xtask scenarios audit, not a number on this page.

Erratum (2026-09-16): only the e2e container interpolates a default (CANOPY_TEST__JURISDICTION: "${CANOPY_JURISDICTION:-georgia}"); every service receives CANOPY_JURISDICTION through the x-canopy-shared-env anchor as "${CANOPY_JURISDICTION:-}", and the shared loader treats the empty value as unset so config/<svc>/default.yaml stands — one export still switches the stack.

Design — grounded current state (code-verified)

  • E2E harness: Playwright projects (tests/e2e/playwright.config.ts); auth-setup chains 9 users; on-demand visual-baseline projects (vb-*) key off CANOPY_E2E_VISUAL_BASELINE (set by xtask e2e --visual); full-stack projects (journey, worker-determination-ele) off CANOPY_E2E_DEVSTACK_PROFILE=full. The longest specs prove dual-context (:8090 applicant + :8080 worker) and cross-service-event journeys already work.

  • Coverage today is default-seed-driven: the generative seeder’s random bulk + phase1b scenario-targeted households + the phase14_cast login-capable applicants (the demo dataset was retired into the default seed in #716); 19 JDM math fixtures (2 shells: snap-eligibility, medicaid-non-magi — crates/canopy-rules-client/tests/ruleset_happy_path_test.rs:52-53); the spec suite. No artifact links any of these to the scenario space; JUnit output lists spec names, not scenarios.

  • Change-reporting surface: endpoints exist (POST …​/change-report + program-parameterized variants, canopy-renewals/src/api/mod.rs:545,677) but change_type is a free string and only income_change marks requires_redetermination — most of the 273.12 space is recordable but not actionable; the inventory makes that visible per-type.

  • Jurisdiction: threaded per-service at startup via CANOPY_*__JURISDICTION (single-tenant per ADR-006); seed/e2e hardcode georgia; rulesets/default/ is a verbatim georgia copy; the test literals (23/19 at recon, 46/19 by MR6’s landing) now route through canopy_test_lib::test_jurisdiction() (MR6, #762). The per-jurisdiction artifact set is known (georgia: 34 files — jurisdiction.toml, citations.toml, theme, idp, composition x5, workflows x9, notices tree, param JSONs).

Design — decisions

  • The inventory tracks scenarios, not personas. Personas are seeded instances; a scenario is the policy-derived situation class. A scenario row may bind to a persona (via the demo seed) as its fixture, but the inventory axis is the CFR/PAMMS-derived space, so "what’s missing" is measured against policy, not against what we happened to stage.

  • Three complexity tiers with tier-appropriate coverage: unit scenarios are satisfied by JDM fixtures (cheap, exhaustive math edges); flow by existing-style specs; journey only by multi-life-event specs. The gate’s "partial" status (journey bound only to a fixture) prevents tier-laundering; a row bound at its tier but fenced by blocked_by is likewise partial — the binding proves the test exists, the fence that it cannot run — and the audit line prints the fence (◐ partial [Flow] <id> — blocked_by #N). An unbound fenced row stays uncovered; a fenced journey is exempt from the walkthrough-pairing gate like any partial journey (ADR-031 Amendment 2). Erratum (2026-09-07): blocked_by shipped informational at MR1 ("never affects coverage status"); #1681 made it a status input and this bullet was corrected to as-built; the one-time re-label moved the audit from 125 covered / 55 partial / 392 uncovered to 118 / 62 / 392 (seven bound-but-fenced rows, uncovered unchanged).

  • Uncovered is a report, dangling is an error. A binding that doesn’t resolve is a lie and fails CI; an honest gap is the burndown metric (mirrors quality-budgets philosophy — debt visible and monotonically shrinking, not hidden).

  • Journeys are full-stack-gated, not pre-push. The pre-push battery stays fast; journeys run on the full devstack in CI and locally on demand (cargo xtask e2e --devstack-profile full — --project journey).

  • Two corpora, one schema (ADR-032). The engine corpus (universal + election-dependent scenarios against synthetic test-min/test-max) answers "does canopy implement the federal option space?" and runs in canopy CI; conformance packs (rulesets/{jurisdiction}/scenarios/) answer "does this configured deployment behave per its policy?" and are each jurisdiction’s ship gate — Georgia’s pack is the UAT suite and the onboarding template. Georgia policy is deliberately NOT the engine corpus: un-elected option arms would go permanently untested, and real-value churn would rot the goldens.

  • Synthetic pair, not a second real state (supersedes the earlier single-testland sketch). Adversarially-elected test-min/test-max fixtures exercise both arms of every referenced election (a single fixture cannot); round numbers + federally-cited elections keep ADR-011 discipline without importing a second state’s policy-reading cost. A real jurisdiction onboarding later inherits the conformance-pack path instead.

Verification

  • Gate unit tests (fixture inventory + fixture spec tree: resolving binding, dangling binding → error, tier-mismatch → partial; shell-fixture binding rejected).

  • MR4’s journey runs green in the demo pipeline; screenshots + the journey’s step assertions reviewed against the design renders where UI is touched (project screenshot-verify convention).

  • MR5: test-min + test-max smokes green in their scheduled job; at least one asserted test-min-vs-test-max behavioral divergence per elected option arm (proves the elections actually flow); policy audit green over both fixtures (election keys cite the option registry, values cite the fixture-design appendix, fixture source kind rejected outside rulesets/test-*).

  • Each MR through the standard gate (validate + D1-D8 + force-merge squash=false).

Appendix — fixture design (MR5, #761; ADR-032 §2/§4)

The design authority every authority = "fixture" citation in rulesets/test-min/citations.toml and rulesets/test-max/citations.toml references (source_ref = "plans/scenario-inventory-e2e.adoc#fixture-design"). The VALUES themselves live in the fixture files (the audit’s ValueMismatch check keeps citation and file in lockstep); this appendix records the rules that produced them and the election matrix.

Personalities

  • test-min — the smallest legal deployment: enabled_programs = ["snap"] only (its jurisdiction.toml carries the snap + shared/jurisdiction/ notices/appeals sections, plus the 13 cross-program keys two snap-only services load unconditionally — the ADR-005 degradation arm made concrete); every federal option DECLINED where law permits (no BBCE ⇒ live asset test, no simplified reporting, no heat-and-eat, no TSNAP, no ABAWD waiver, actual-cost self-employment, SUA mandatory, dependent care capped). Erratum (2026-09-11): "ONLY the snap + shared/jurisdiction/notices/appeals sections" was unbootable — canopy-applications reads all five [shared.application_processing] day keys and canopy-reporting reads [tanf.wpr] + [tanf].work_requirement_hours_per_week whatever enabled_programs says (ADR-011 fails loud on a missing key), and both run in the snap-only profile, so test-min could not boot it (#1836); the clause is corrected to as-built and the fixture gained those keys at test-max’s federal values, cited to this appendix.

  • test-max — every program enabled, every optional surface on, most permissive elections (BBCE at the 200% lawful ceiling with the asset test eliminated, simplified reporting, statewide ABAWD waiver, standard self-employment percentage, MAGI adult expansion adopted).

Value rules

  1. Round numbers only — auditable by inspection, immune to indexing churn (money in whole hundreds of cents; percentages in fives/tens; day counts from {5,7,10,14,15,30,45,60,90,180,270}; months from {3,4,6,12,24,36,48,60}).

  2. Federal floors/ceilings are inviolable and identical in BOTH fixtures (expedited 7 days, expedited screening $150/$100, ABAWD 80h/3-in-36, IPV 12/24 months, CHIP floor 134% FPL, TANF federal 60-month limit, WPR 50/90, two-parent 35/55 hours, core-hours 20, processing SOPs 30/7/30/45/45 days, appeal window 90 + decision clock 60 days; the SNAP minimum benefit 2400¢ — 8% of the one-person max allotment, 7 CFR 273.10(e)(2)(ii)©, a floor the adversarial review caught the first draft violating; BBCE gross spans exactly the lawful 130→200 range across the pair). Erratum (2026-11-01): the TANF 30 in the processing list is no federal floor, since no federal TANF processing standard exists (42 USC 617); it stays a round fixture value, identical in both fixtures (#3167).

  3. Wherever an election has an engine or service realization, the pair MUST differ on it — that difference is what the divergence assertions consume.

  4. Identity strings are obviously synthetic (Test-Min/Test-Max Fixture Agency, 1-555-0100, Testville, fips 69/60 — real-but-unused territory codes (Northern Mariana Islands / American Samoa), UTC; holidays are six round dates as OBSERVED weekday shifts — the workday calendar refuses weekend entries at load); [policy_source] type = "manual", no repos (fixtures have no PAMMS). Erratum (2026-09-10): the pair shipped with synthetic fips 00/99, which no reader can resolve — canopy-reporting’s federal-parameter loader and the portal’s jurisdiction-strings loader both fail closed on a code the canopy-reference FIPS table does not know (#1226/#1273), and canopy-caps had no smi-2026.json block for either slug, so three services could not boot either fixture (#1819); the fips clause is corrected to as-built (real-but-unused territory codes, readers untouched) and the fixtures gained synthetic round-number SMI blocks.

  5. Structure-preserving tables: money/limit arrays keep georgia’s LENGTH and monotonic shape with round values; the adverse-action reason vocabulary and the TANF work-activity vocabulary copy georgia verbatim (product surface, not policy values).

  6. Federal-file-mirrored keys keep the shared federal files' EXACT values — the snap param-set loader refuses cross-source divergence (#1467 C5; single-sourcing is #1478): minimum_benefit_amount_cents 2400, homeless_shelter_deduction_monthly_cents 19900 (both caught live by the divergence tests, not the citation audit).

  7. Copied JDM files carry the FIXTURE’s jurisdiction prefix in their embedded name field where georgia’s carried georgia- (services look up {jurisdiction}-<ruleset>); the federal alien-eligibility file’s wrongly georgia-prefixed name is pre-existing debt, filed as #1613.

Election matrix (compliance/federal-options/ ↔ fixture arms)

Registry option Realizing jurisdiction key(s) test-min arm test-max arm Realization

snap.bbce

snap.bbce_enabled, snap.bbce_gross_income_limit_pct_fpl, snap.bbce_elderly_disabled_gross_pct_fpl, snap.bbce_asset_test_eliminated

not-elected

elected

engine/service

snap.simplified-reporting

snap.simplified_reporting, snap.periodic_reporting.*

not-elected

elected

engine/service

snap.esap

[snap.certification.esap] (present = elected)

not-elected

elected

registry-only

snap.transitional-benefits

snap.transitional_benefits_enabled

not-elected

elected

registry-only

snap.abawd-geographic-waiver

snap.abawd_waiver_active, snap.abawd_waiver_areas

no-waiver

waiver-in-effect

registry-only

snap.abawd-discretionary-exemptions

snap.abawd.discretionary_exemption_pct

not-utilized

utilized

registry-only

snap.comparable-disqualification

none (registry-only)

not-elected

elected

registry-only

snap.self-employment-expense-method

snap.self_employment.standard_deduction_enabled, snap.self_employment.standard_deduction_pct, snap.self_employment.boarder_income_deduction_method

actual-costs

standard-percentage

engine/service

snap.drug-felony-policy

snap.disqualifications.drug_felony_policy, snap.disqualifications.drug_treatment_exemption

full-ban

opt-out

registry-only

snap.sua-methodology

snap.sua.allow_actual_utility_costs

mandatory-sua

household-choice

registry-only

snap.child-support-treatment

none (registry-only)

deduction

income-exclusion

registry-only

snap.vehicle-exclusion-methodology

snap.vehicle_fair_market_value_excluded

snap-standard

tanf-rule-substitution

registry-only

snap.group-hearings

none (registry-only)

not-elected

elected

registry-only

snap.claims-establishment-threshold

snap.overpayment.not_participating_floor_cents, snap.overpayment.participating_floor_cents, snap.overpayment.floor_claim_bases, snap.overpayment.quality_control_bypasses_floors

default-125

approved-plan-threshold

engine/service

tanf.lifetime-limit

tanf.time_limit_months, tanf.federal_time_limit_months

not-applicable (program not enabled)

federal-60-months

engine/service

tanf.hardship-extension

none (registry-only)

not-applicable (program not enabled)

elected

registry-only

tanf.family-violence-option

none (registry-only)

not-applicable (program not enabled)

elected

registry-only

tanf.work-sanction-structure

tanf.sanctions.*

not-applicable (program not enabled)

graduated-partial-then-full-family

registry-only

tanf.infant-exemption

tanf.wpr.infant_exemption_months_max

not-applicable (program not enabled)

elected

engine/service

tanf.ivd-sanction-scope

none (registry-only)

not-applicable (program not enabled)

reduce-at-least-25pct

registry-only

tanf.drug-felony-policy

none (registry-only)

not-applicable (program not enabled)

opt-out

registry-only

tanf.individual-responsibility-plan

none (registry-only)

not-applicable (program not enabled)

elected

registry-only

tanf.deprivation-eligibility

none (registry-only)

not-applicable (program not enabled)

required

registry-only

tanf.assistance-unit-composition

none (registry-only)

not-applicable (program not enabled)

mandatory-standard-filing-unit

registry-only

tanf.need-standard-design

none (the tanf-eligibility decision of the pack, over [tanf.standards] and [tanf.values])

not-applicable (program not enabled)

gross-ceiling-and-standard-of-need

engine/service

tanf.earned-income-disregard

none (the tanf-eligibility decision of the pack, over [tanf.values])

not-applicable (program not enabled)

standard-work-deduction

engine/service

tanf.diversion-program

none (registry-only)

not-applicable (program not enabled)

elected

registry-only

tanf.pregnant-individual-coverage

none (registry-only)

not-applicable (program not enabled)

covered

registry-only

medicaid.medically-needy

medicaid.mnil_income_limit_by_bg_size, medicaid.mnil_income_limit_each_additional, medicaid.abd_mnil_individual, medicaid.abd_mnil_couple

not-applicable (program not enabled)

elected

engine/service

medicaid.institutional-income-cap

none (registry-only)

not-applicable (program not enabled)

special-income-level-elected

registry-only

medicaid.express-lane-eligibility

shared.timing.ele_renewal_sweep_window_days

not-applicable (program not enabled)

elected

registry-only

medicaid.section-1115-demonstration

medicaid.pathways_enabled, medicaid.pathways_income_limit_pct_fpl, medicaid.pathways_work_hours_per_month, medicaid.pathways_min_age, medicaid.pathways_max_age

not-applicable (program not enabled)

no-demonstration

engine/service

medicaid.extended-postpartum-12-months

none (registry-only)

not-applicable (program not enabled)

elected

registry-only

chip.waiting-period

none (registry-only)

not-applicable (program not enabled)

none

registry-only

chip.premiums

medicaid.peachcare_premiums.tiers, medicaid.peachcare_premiums.exempt_under_age, medicaid.peachcare_premiums.exempt_foster_care, medicaid.peachcare_premiums.exempt_american_indian

not-applicable (program not enabled)

imposed-per-public-schedule

engine/service

caps.initial-income-threshold

caps.income_limit_initial_pct_smi

not-applicable (program not enabled)

85-pct-smi-maximum

engine/service

caps.graduated-phase-out-threshold

caps.income_limit_continued_pct_smi

not-applicable (program not enabled)

85-pct-smi

engine/service

caps.job-search-continuation-period

none (registry-only)

not-applicable (program not enabled)

extended

registry-only

caps.copayment-waiver

none (registry-only)

not-applicable (program not enabled)

waivers-elected

registry-only

caps.presumptive-eligibility

none (registry-only)

not-applicable (program not enabled)

elected

registry-only

wic.breastfeeding-cert-one-year

none (registry-only)

not-applicable (program not enabled)

elected

registry-only

wic.infant-cert-to-first-birthday

none (registry-only)

not-applicable (program not enabled)

elected

registry-only

wic.child-annual-certification

none (registry-only)

not-applicable (program not enabled)

elected

registry-only

wic.processing-standard-15-day-extension

none (registry-only)

not-applicable (program not enabled)

extension-permitted

registry-only

wic.food-delivery-system

none (registry-only)

not-applicable (program not enabled)

retail

registry-only

Erratum (2026-11-06): the snap.abawd-discretionary-exemptions row's pack key is now snap.abawd.discretionary_exemptions_per_year (#3220), whose empty table is the not-utilized arm; snap.abawd.discretionary_exemption_pct never had a reader and is gone from every pack (#3235).

Erratum (2026-11-01): #3203 replaced medicaid.pathways_enabled and medicaid.pathways_work_hours_per_month with the [medicaid.adult_demonstration] section, so the medicaid.section-1115-demonstration row’s keys are medicaid.adult_demonstration. and the remaining pathways_ income and age keys.

Erratum (2026-09-23): #936 realized snap.claims-establishment-threshold in canopy-snap’s overpayment recompute, so its row is corrected to as-built — the single minimum_claim_cents became the four [snap.overpayment] keys and the realization is engine/service. The pair diverges on it (test-min 12500 / 0, test-max 25000 / 20000), asserted by the in-crate canopy-snap test fixture_pair_diverges_on_the_participating_floor.

not-applicable (program not enabled) rows are the program-subset divergence itself: test-min proves the stack RUNS without those services (ADR-005), which is the elected-arm assertion for every option of a program test-min omits.

Divergence assertions (the "elections actually flow" proof)

Scoped to options with a live realization on BOTH sides of the pair — narrower than the MR row’s original "per elected option arm" phrasing, and deliberately so (a registry-only option has no realization to assert; recorded here per ADR-013 living-spec):

  1. snap.self-employment-expense-method — the engine-registered SNAP divergence: SnapParameterSets::load (the REAL boot loader) yields standard_deduction_enabled false/true and the elected 50% only under test-max (in-crate canopy-snap test fixture_pair_diverges_on_the_self_employment_election — battery-gated). These values feed se_deduction and the snap-self-employment-deduction JDM.

  2. snap.bbce — runtime realization is the renewals gross screen: RenewalParams::load yields gross_income_limit_pct 130 (no BBCE, federal base) vs 200 (the lawful BBCE ceiling) — in-crate canopy-renewals test fixture_pair_diverges_on_the_bbce_gross_screen. (The engine’s asset-test thresholds come from the SHARED federal deductions file, not jurisdiction.toml — the loader REFUSES divergence on federal-mirrored keys, see value rule 6 — so the bbce booleans' remaining realization is the seed/scenario layer, as the matrix records.)

  3. Corpus bootability — NamedFilesystemLoader::scan over [federal, test-*] scans clean and registers each fixture’s OWN jurisdiction-prefixed SNAP eligibility ruleset (in-crate canopy-rules test fixture_corpora_scan_clean_like_a_service_boot): exactly the load the rules service performs at boot.

  4. Program-subset options — existential: the scheduled fixture-smoke lane boots test-min snap-only and test-max full and both smoke green (sign-in, dashboard, one determination, one notice).

Erratum (2026-09-11): #1827 deleted canopy-renewals' local FPL table (its 130%-FPL screens now read the figures the determination scored with), taking RenewalParams' gross_income_limit_pct and the snap.bbce assertion above with it. The assertion is re-homed to the in-crate canopy-policy test fixture_pair_diverges_on_the_bbce_gross_limit, which resolves the same 130-vs-200 divergence through PolicyParams::resolve — the election’s remaining live reader, and the one the seed/scenario layer prices against.

Boot seams this MR added

  • docker-compose.yml: every jurisdiction consumer reads ${CANOPY_JURISDICTION:-georgia} (one export switches the stack).

  • cargo xtask e2e --jurisdiction parameterizes the SEED (default georgia; the bare battery is byte-identical).

  • canopy-notices falls back to rulesets/default/notices templates when a jurisdiction ships none — fail-closed outside CANOPY_ENV=dev behind CANOPY_NOTICES__ALLOW_DEFAULT_TEMPLATE_FALLBACK (#1265 doctrine); the fixtures deliberately ship no template tree.

  • Citation kinds: fixture (this appendix; staleness-exempt; rejected outside rulesets/test-*) and option_registry (source_ref must be a live compliance/federal-options/ key) — both audit-enforced.

Edit this page · default