Scoring Models · ZIP Product Mix Predictor (agency + Non-QM composition per ZIP)
What it does
Composed multi-model that returns the expected mortgage product-mix distribution for a US ZIP code, optionally refined by a borrower profile. Under the hood: (1) a Jumbo pre-model rule comparing loan amount to the 1-unit conforming limit ($806,500 in 2025); (2) a 4-class agency classifier (Conv / FHA / VA / USDA) trained on 17.5M HMDA 2022-2025 first-lien originations — test top-1 accuracy 77.9% (vs 70% "always predict Conv" baseline), top-2 accuracy 93.7%, calibrated log-loss 0.563; (3) a Non-QM binary side-model trained on 4.0M Optimal Blue lock records with OOT AUC 0.97 full-feature, 0.87 HMDA-only fallback. Non-QM output blends into the Conv slice at inference. Coverage: 20,417 US ZIPs (~50% of the ~42K USPS ZIP universe) — every ZCTA with ≥1 HMDA 2022-2025 origination.
Fair-lending verdict: CONDITIONAL_PASS —
MARKET-ESTIMATION ONLY. Traditional argmax AIR fails on FHA / VA
/ USDA because the underlying market has real 3-4× demographic
differentials in agency-product usage (a well-documented Housing Finance
Policy Center finding); a model that passed would have to falsify that.
BUT: the model does NOT amplify demographic bias —
it regresses to the mean, attenuating the raw-data gap by roughly half.
And on the Conv-feasible-profile subset, all race / ethnicity / sex groups
receive Conv predictions 94%+ of the time (AIR 0.95+) — the model
does NOT steer eligible borrowers away from Conv. See the
usage_verdict field in every response for the approved /
prohibited use-case list.
Why it matters. ZIP-level product-mix estimation is the right lens for three operator questions the loan-level scoring models don't answer: (1) capacity planning — "if we open a branch or expand a broker panel in ZIP X, what agency mix should we staff for?"; (2) MSR / capital-markets pipeline forecasting — "expected FHA vs Conv volume in Metro Y next quarter given the rate anchor and demographic tilt"; (3) product-mix trend reporting — a ZIP-level baseline for detecting geographic shifts in Non-QM adoption or FHA share over time. The response includes a full probability distribution across six classes (Conv / FHA / VA / USDA / Jumbo / Non-QM) so consumers can consume the whole shape, not just the mode.
What it is NOT. This is NOT an individual borrower routing tool. Do not use it to tell a specific borrower which product they should take, do not use it as a "recommended product" script for LO conversations, and do not use it in any workflow that could steer a Conv-eligible borrower away from Conv. The Phase 4 fair-lending audit produced a CONDITIONAL_PASS specifically because the model faithfully reflects (without amplifying) real market demographic imbalance — that's fine for aggregate estimation, ECOA-risky for individual decisioning.
Enrichment. The endpoint takes a ZIP + optional borrower fields and server-side enriches with the modal state code, modal HMDA MSA/MD code, loan-weighted tract demographics (minority %, MSA-relative income, owner-occupied units, housing age, 1-4-family stock, population), and state proxies (20yr HPA, unemployment, disaster risk, employment HHI) plus the annual PMMS30 rate anchor — all pinned to the latest HMDA vintage with complete tract data (currently 2024, since 2025 tract derivations backfill after the annual snapshot closes).
› Try it on the home page (Loan-level model scoring → ZIP Product Mix)
API connector
Programmatic access. Calibrated probability + risk band + operating recommendation in the response.
POST /api/score_zip_product
Content-Type: application/json
{
"zip_code": "94103", // REQUIRED; 5-digit US ZIP
"loan_amount": 500000, // triggers Jumbo rule if > conforming limit
"loan_purpose": "1", // 1=purchase, 2=home-improv, 31=refi, 32=cashout
"occupancy_type": "1", // 1=primary, 2=second, 3=investment
"dti_band": "36%-<43%", // HMDA banded DTI
"income_thousands": 120,
"total_units": "1",
"loan_term_months": 360,
"applicant_age": "35-44" // HMDA age band
}
Response includes product_distribution (6 keys: Conv, FHA,
VA, USDA, Jumbo, Non-QM — each with a label + probability),
top_product + top_product_probability, the
ZIP's modal state and MSA, whether the Jumbo pre-model rule fired,
the raw p_nonqm_sidemodel, and a prominent
usage_verdict object listing approved / prohibited use
cases from the Phase 4 fair-lending audit. Uncovered ZIPs return 400
with a message directing the caller to try a nearby ZIP.
Schema reference (request / response shape): GET /api/score_zip_product/schema
Model metadata (training cohort, AUC, calibration): GET /api/score_zip_product/info
mortgagetape™