Skip to content

Instantly share code, notes, and snippets.

@simbo1905
Created June 11, 2026 08:17
Show Gist options
  • Select an option

  • Save simbo1905/beb41dd8e5fe7fe83b63246c24b83386 to your computer and use it in GitHub Desktop.

Select an option

Save simbo1905/beb41dd8e5fe7fe83b63246c24b83386 to your computer and use it in GitHub Desktop.
Livemore Pricing Engine — Margin Monitor UAT Runbook and Results 2026-06-11 SHA:3017271f

Margin Monitor UAT Results

Run date: 2026-06-11 | SHA: 3017271f | Tester: autonomous UAT agent (Claude)

All tests run against live dev1 instance over NordLayer VPN. Browser: Edge with Kapture automation. All values extracted from live DOM.


Quick Summary

Test Description Result
SYS001 SHA matches master HEAD ✅ PASS
MMD001 Screen loads with KPIs and Market Inputs ✅ PASS
MMD002 Reload button fetches and renders LM rates ✅ PASS
MMD003 All 7 groups visible with rates ✅ PASS
MMP001 Single rate edit propagates to Net Fee ✅ PASS
MMP002 Zig-zag 7-group edit Standard (±1.01–1.07) ✅ PASS 7/7
MMP003 Zig-zag 7-group edit RIO (±1.31–1.37) incl FFL ✅ PASS 7/7
MMG001 Target margin shifts row-below count ✅ PASS
MMG002 BoE shift exact inverse ±100bps ✅ PASS
MMG003 Citi rate inputs propagate to swap column ✅ PASS 5/5
MMN001 Date navigation loads real historical Citi rates ✅ PASS 5/5
MMN002 Family Standard↔RIO loads different data ✅ PASS
MMN003 Group selector single↔all ✅ PASS

13/13 PASS ✅


SYS001 — Deploy SHA Verification

GET /health
→ VERSION_GIT_SHA: 3017271f8cdf8b2f100caec38a403c482183915e
→ VERSION_GIT_BRANCH: master
→ VERSION_BUILD_TIMESTAMP: 2026-06-11T05:38:57Z
→ VERSION_BUILD_WORKFLOW: Pricing Engine - Deploy

Matches git log -1 --format=%H on local master. PASS ✅


MMD001–003 — Screen Load and Data Render

Baseline state (Standard, group=all, date=2026-06-03, after reload):

  • KPI Upfront: 228 bps | 22 rows below threshold
  • KPI FA: 253 bps | 13 rows below threshold
  • Market Inputs date: 2026-06-03 (Citi curve loaded)
  • Product Inputs date: 2026-04-10 (latest lm_rates in DB)
  • Groups visible: 7 (LM1 0-60, LM1 75, LM2 0-60, LM2 75%, LM2 80%, LM3 75%, LM4 0-60)

Sample input — LM1 (0-60) before any edits:

Metric 2y 3+2yr 5y 5+5yr 10y
Upfront Fee Rate 6.3300 5.8300 5.9300 6.2400 6.2900
Fee Assisted Rate 6.7500 6.0800 6.1800 6.4200 6.4700

Sample output — LM1 (0-60) before any edits:

Metric 2y 3+2yr 5y 5+5yr 10y
Upfront Fee Rate 6.33% 5.83% 5.93% 6.24% 6.29%
Swap 4.24% 4.25% 4.25% 4.50% 4.50%
Net Fee 2.09% 1.58% 1.68% 1.74% 1.79%
Threshold 2.30% 2.30% 2.30% 2.30% 2.30%

PASS ✅


MMP002 — Zig-Zag Edit Standard (±1.01–1.07)

Inputs applied:

Group Term edited Before Delta After
LM1 (0-60) 2y 6.3300 +1.01 7.3400
LM1 (75) 3+2yr 5.9300 −1.02 4.9100
LM2 (0-60) 5y 6.2300 +1.03 7.2600
LM2 (75%) 5+5yr 6.6400 −1.04 5.6000
LM2 (80%) 10y 6.7900 +1.05 7.8400
LM3 (75%) 2y 7.3300 −1.06 6.2700
LM4 (0-60) 3+2yr 7.0300 +1.07 8.1000

KPI after edits: 231 bps upfront (was 228) — net positive from more + than − edits.

Verification — Net Fee delta equals input delta:

Group Term Net Fee before Net Fee after Actual Δ Expected Δ Match
LM1 (0-60) 2y 2.09% 3.10% +1.01% +1.01%
LM1 (75) 3+2yr 1.68% 0.66% −1.02% −1.02%
LM2 (0-60) 5y 1.98% 3.01% +1.03% +1.03%
LM2 (75%) 5+5yr 2.14% 1.10% −1.04% −1.04%
LM2 (80%) 10y 2.29% 3.34% +1.05% +1.05%
LM3 (75%) 2y 3.09% 2.03% −1.06% −1.06%
LM4 (0-60) 3+2yr 2.78% 3.85% +1.07% +1.07%

4 threshold crossings occurred (BELOW↔ABOVE) — consistent with deltas applied. PASS ✅


MMP003 — Zig-Zag Edit RIO (±1.31–1.37)

RIO baseline vs Standard (confirming different family):

Property Standard RIO
KPI Upfront 228 bps 266 bps
Terms 5 6 (adds FFL)
LM1(0-60) 2y rate 6.3300 6.5400

RIO edits and verification:

Group Term Before Delta After Net Fee Δ Match
LM1 (0-60) 2y 6.5400 +1.31 7.8500 +1.31%
LM1 (75) 3+2yr 6.2300 −1.32 4.9100 −1.32%
LM2 (0-60) 5y 6.5300 +1.33 7.8600 +1.33%
LM2 (75%) 5+5yr 6.8400 −1.34 5.5000 −1.34%
LM3 (0-60) 10y 7.5900 +1.35 8.9400 +1.35%
LM3 (75%) FFL 7.9900 −1.36 6.6300 −1.36%
LM4 (0-60) 2y 7.8400 +1.37 9.2100 +1.37%

FFL (Further Fixed Life) term — present in RIO only — propagates correctly. PASS ✅


MMG001 — Target Margin

State Target Rows below (upfront) Rows below (FA)
Baseline 2.30% 22 13
+25bps 2.55% 22 21 (↑)
−36bps 1.94% 10 (↓) 4 (↓)

Higher threshold → more rows below → more red. Lower threshold → fewer rows below. PASS ✅


MMG002 — BoE Shift

BoE Shift KPI Upfront KPI FA Swap 2y Rows below
0 (baseline) 231 bps 253 bps 4.24% 22
+100 bps 131 bps (−100) 153 bps (−100) 5.24% (+1.00) 33
−100 bps 331 bps (+100) 353 bps (+100) 3.24% (−1.00) 2

Exact ±100bps on KPI. Exact ±1.00% on swap column. PASS ✅


MMG003 — Citi Swap Rate Inputs

Edits applied (alternating sign, all 7 terms): 2y +1.11%, 5y −1.12%, 10y +1.13%, 15y −1.14%, 20y +1.15%, 30y −1.16%, FFL +1.17%

Term Swap before Swap after Delta Output swap Δ Match
2y 4.2373% 5.3473% +1.11% +1.11%
5y (→3+2yr) 4.2470% 3.1270% −1.12% −1.12%
10y 4.4987% 5.6287% +1.13% +1.13%
10y (→5+5yr) 4.4987% 5.6287% +1.13% +1.13%
2y (→2y) 4.2373% 5.3473% +1.11% +1.11%

KPI: 231→208 bps (net swap cost rose → margin fell). PASS ✅


MMN001 — Citi Date Navigation (Jan–Jun 2026)

Date 2y Swap 10y Swap KPI Net Fee 2y LM1(0-60) Swap↑→Margin↓?
2026-01-05 3.4965% 4.0287% 284 bps 2.83%
2026-02-02 3.5387% 4.1176% 277 bps 2.79%
2026-03-02 3.4681% 3.9510% 291 bps 2.86% ✅ (rates dipped, margin up)
2026-04-01 4.1825% 4.3793% 238 bps 2.15%
2026-05-01 4.2865% 4.5040% 226 bps 2.04%
2026-06-03 4.2373% 4.4987% 228 bps 2.09%

Rate spike Jan→Apr 2026: +69bps on 2y swap → −46bps on margin, rows below threshold 5→19. (Context: market event early spring 2026 drove rates up.)

5/5 month transitions show inverse swap↔margin. PASS ✅


MMN002 — Family Standard↔RIO

Standard: 228 bps, 5 terms, LM1(0-60) 2y = 6.3300% RIO: 266 bps (+38bps), 6 terms (adds FFL), LM1(0-60) 2y = 6.5400%

Confirmed different product family, different DB data. PASS ✅


Evidence Files

Test Files
MMP002 MM_STD_ZIGZAG.zip — inputs, outputs, screenshot
MMP003 MM_RIO_ZIGZAG.zip — inputs, outputs, screenshot
MMG001 MM_TARGET_MARGIN.zip — screenshots ±25/−36bps
MMG002 MM_BOE_SHIFT.zip — screenshots ±100bps
MMG003 MM_CITI_INPUTS.zip — screenshot after edits
MMN001 MM_DATE_NAV.zip — 6 screenshots Jan–Jun 2026
Full report UAT_REPORT.md

All tests black-box against live dev1. No mocking. Source: live DB, live S3, live scheduled task.

Margin Monitor UAT Runbook

Livemore Pricing Engine — Reusable Test Script

Version: 1.0 | Last run: 2026-06-11 | SHA tested: 3017271f

This document is the reusable test script. Run it against any dev1 or prod deploy. Results go in a separate MM_RESULTS_<date>.md per run.


Prerequisites

  • NordLayer VPN connected (verify: curl https://dev1-pricing-engine.livemoremortgages.com/health → 200)
  • Browser open to dev1 (Edge preferred, Kapture extension for automation)
  • AWS credentials active (770763521444_DataAccess profile, eu-west-2) for log checks

Test Class Legend

Prefix Area
SYS System health and deploy verification
MMD Margin Monitor — data load and screen render
MMP Margin Monitor — product input rate editing
MMG Margin Monitor — global inputs (target margin, BoE shift, Citi rates)
MMN Margin Monitor — navigation (date picker, family, group selectors)

SYS001 — Deploy SHA Verification

Purpose: Confirm the deployed version matches the expected git SHA.

Steps:

  1. curl https://dev1-pricing-engine.livemoremortgages.com/health
  2. Extract version.VERSION_GIT_SHA from JSON response
  3. Compare to git log -1 --format=%H on the branch under test

Pass: SHA matches exactly. Fail: SHA differs — wrong version deployed.


MMD001 — Margin Monitor Screen Load (Standard, Group 0)

Purpose: Confirm screen renders with data, KPI tiles populated, Market Inputs loaded.

Steps:

  1. Navigate to: /v1/margin_monitor.html?family=standard&group=0&date=<latest_citi_date>&show_rates=1&show_charts=1&show_tables=1
  2. Observe: KPI tiles show numeric bps values (not "loading…")
  3. Observe: Market Inputs section shows Citi swap rate values (not blank)
  4. Observe: Product Inputs shows #### (correct unloaded state per spec)

Pass: KPIs non-zero, Market Inputs populated, Product Inputs shows ####.


MMD002 — Product Inputs Reload

Purpose: Confirm the reload button fetches and renders LM gross rates.

Steps:

  1. From MMD001 state, click the reload/recycle icon button in the Product Inputs header
  2. Wait ~2 seconds
  3. Observe: Product Inputs header changes from ____-__-__ to a real date (YYYY-MM-DD)
  4. Observe: Rate cells show numeric values (e.g. 6.3300) instead of ####

Pass: Rates load, date shown in header. Fail: Still #### after click, or error banner appears.


MMD003 — All Groups Expand

Purpose: Confirm all product groups render when Group = All Groups.

Steps:

  1. Navigate to same URL but with group=all
  2. After reload button click, observe: multiple product group tables visible (LM1 0-60, LM1 75, LM2 0-60, etc.)
  3. Count groups visible — Standard family should show 7 groups

Pass: 7 groups visible with rate values.


MMP001 — Single Rate Edit Propagates to Output (Standard)

Purpose: Confirm editing one Upfront Fee Rate cell changes Net Fee in the output table.

Setup: MMD003 complete (rates loaded, group=all).

Steps:

  1. Note current value of LM1 (0-60) Upfront Fee Rate, 2y term (e.g. 6.3300)
  2. Note current Net Fee 2y in output table (e.g. 2.09%)
  3. Click the 2y rate cell, change value to 7.3300 (+1.00)
  4. Tab or click away
  5. Observe Net Fee 2y in output table

Pass: Net Fee 2y increases by exactly 1.00% (e.g. 3.09%). All other terms unchanged. Fail: Net Fee did not change, or changed by wrong amount, or other terms changed.


MMP002 — Zig-Zag Multi-Group Edit (Standard, ±unique decimals)

Purpose: Confirm edits propagate independently across all 7 groups with no cross-contamination.

Setup: Fresh page load, MMD003 complete.

Steps: Apply one edit per group, alternating sign, moving right-then-down the page:

Step Group Term col Value to enter Delta
1 LM1 (0-60) 2y (col 1) baseline + 1.01 +1.01%
2 LM1 (75) 3+2yr (col 2) baseline − 1.02 −1.02%
3 LM2 (0-60) 5y (col 3) baseline + 1.03 +1.03%
4 LM2 (75%) 5+5yr (col 4) baseline − 1.04 −1.04%
5 LM2 (80%) 10y (col 5) baseline + 1.05 +1.05%
6 LM3 (75%) 2y (col 1) baseline − 1.06 −1.06%
7 LM4 (0-60) 3+2yr (col 2) baseline + 1.07 +1.07%

After all edits, for each group check: Net Fee in the edited term column changed by exactly the delta entered. Unedited terms in that group unchanged. Other groups' unedited terms unchanged.

Take full-page screenshot. Download all output CSVs (Download CSV button per chart).

Pass: 7/7 groups show exact delta. Screenshot shows edited values. CSVs match DOM. Fail: Any group shows wrong delta, or cross-contamination in other terms.


MMP003 — Zig-Zag Multi-Group Edit (RIO family, ±unique decimals)

Purpose: Same as MMP002 but for RIO family. Confirms RIO is a separate model with FFL term.

Setup: Navigate to family=rio&group=all, reload product inputs.

Steps: Apply one edit per group:

Step Group Term col Delta
1 LM1 (0-60) 2y +1.31%
2 LM1 (75) 3+2yr −1.32%
3 LM2 (0-60) 5y +1.33%
4 LM2 (75%) 5+5yr −1.34%
5 LM3 (0-60) 10y +1.35%
6 LM3 (75%) FFL (col 6) −1.36%
7 LM4 (0-60) 2y +1.37%

Also verify: RIO baseline KPI ≠ Standard baseline KPI. RIO has FFL column. RIO rates higher.

Pass: 7/7 exact deltas including FFL. RIO KPI differs from Standard by ≥30 bps.


MMG001 — Target Margin Shift

Purpose: Confirm changing target margin moves the threshold red line and changes row-below-threshold count.

Setup: Standard, group=all, rates loaded (MMD003).

Steps:

  1. Note current target margin value (default 2.30%) and "rows below threshold" count from KPI tiles
  2. Change target margin to 2.5500 (+25bps)
  3. Observe: "rows below threshold" count increases (more rows fall below the higher bar)
  4. Change target margin to 1.9400 (−36bps from original)
  5. Observe: "rows below threshold" count decreases (fewer rows below the lower bar)

Pass: rows-below increases on higher target, decreases on lower target. KPI bps unchanged (weighted margin is not affected by threshold). Fail: rows-below moves wrong direction, or KPI bps changes.


MMG002 — BoE Shift Inverse Relation

Purpose: Confirm BoE shift changes swap costs and moves margin inversely by exact amount.

Setup: Standard, group=all, rates loaded, target margin reset to 2.30.

Steps:

  1. Note KPI bps (e.g. 228 bps upfront) and Swap column in any output table (e.g. 4.24% for 2y)
  2. Set BoE Shift to 100 (+100bps)
  3. Observe: KPI bps drops by ~100 bps (e.g. 228→128). Swap column increases by 1.00% (e.g. 4.24→5.24)
  4. Set BoE Shift to -100 (−100bps)
  5. Observe: KPI bps rises by ~100 bps (e.g. 228→328). Swap column decreases by 1.00%

Pass: Exact ±100 bps on KPI. Exact ±1.00% on Swap column. Inverse at each step. Fail: Wrong magnitude, wrong direction, or non-exact.


MMG003 — Citi Swap Rate Input Edit

Purpose: Confirm editing individual Citi rate inputs changes swap costs and margin inversely.

Setup: Standard, group=all, rates loaded, BoE reset to 0.

Steps: Edit all 7 amber Citi rate inputs (2y, 5y, 10y, 15y, 20y, 30y, FFL) with alternating sign:

Term Delta
2y +1.11%
5y −1.12%
10y +1.13%
15y −1.14%
20y +1.15%
30y −1.16%
FFL +1.17%

After each batch of edits, verify: Swap column in output table for the corresponding product term moved by the same delta. Net Fee moved inversely.

Pass: 5+ verifiable term swaps match. KPI moves in direction consistent with net swap change.


MMN001 — Citi Curve Date Navigation

Purpose: Confirm navigating to different historical dates loads genuinely different Citi swap rates from DB.

Steps:

  1. Navigate to 6 dates (first business day of each month, Jan–Jun current year)
  2. At each date, record: 2y swap rate, 10y swap rate, KPI bps, Net Fee 2y for LM1(0-60)
  3. Verify: each date shows different swap rate values (rates are not static/cached)
  4. Verify: month-on-month, swap rate changes and KPI move in opposite directions (inverse relation)

Pass: All 6 dates show different swap values. 5/5 month-on-month transitions show inverse swap↔margin. Fail: Rates identical across dates (cached), or same-direction movement.


MMN002 — Family Selector (Standard ↔ RIO)

Purpose: Confirm switching family loads different rates, different group names, different KPI.

Steps:

  1. Load Standard family, note KPI and LM1(0-60) 2y Upfront Rate
  2. Switch URL to family=rio, reload product inputs
  3. Confirm: KPI differs by ≥30 bps. LM1(0-60) 2y rate is higher. FFL term column present (RIO only).

Pass: Measurably different KPI, different rates, FFL column appears.


MMN003 — Group Selector (Single ↔ All)

Purpose: Confirm group selector controls which product tables are shown.

Steps:

  1. Load group=0 — observe one product group visible (LM1 0-60)
  2. Switch to group=all — observe all 7 groups visible
  3. KPI tiles should remain same (they are weighted across all groups regardless)

Pass: Group count changes correctly. KPI stable.


Download Evidence Protocol

After each MMP/MMG test, collect:

  1. Full-page screenshot (scale 0.25–0.3)
  2. Download CSV for each margin chart (shows chart data numerically)
  3. Image PNG for each chart (visual evidence)
  4. Download CSV for each output table
  5. Verify: downloaded CSV values match DOM-visible values

End of runbook. For results, see MM_RESULTS_<date>.md.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment