From 2caab6aa691c66bcde4592d3489557404de2c5c1 Mon Sep 17 00:00:00 2001 From: justin Date: Sun, 14 Jun 2026 21:02:08 -0500 Subject: [PATCH] hc: warmup must run DAILY for the full 21-day ramp (not weekdays-only) The HC warmup crons were '* * 1-5' (Mon-Fri), silently skipping weekends -- but a proper warmup needs CONTINUOUS daily volume for 21 days (mailbox providers reward consistency; gaps stall reputation). The Jun 14 'HC 0 sent' alert was just a skipped Sunday, but the weekend skips also broke ramp continuity. - pw-hc-campaign + pw-hc-nppes: '* * 1-5' -> '* * *' (daily), vendored + applied live. - Re-aligned the warmup start stamp from calendar-day 9 to send-day 5 so the volume ramp matches reputation actually built (it had skipped ~4 weekend days, running the ramp ahead of real history). - Fixed the stale 'Mon-Fri only' comment in daily_slice(). - Vendored nppes cron now carries the enriched-CSV + 4-segment config. --- infra/cron/pw-hc-campaign | 2 +- infra/cron/pw-hc-nppes | 12 ++++++------ scripts/build_healthcare_campaigns_cron.py | 3 ++- 3 files changed, 9 insertions(+), 8 deletions(-) diff --git a/infra/cron/pw-hc-campaign b/infra/cron/pw-hc-campaign index 8dc1a1d..843d4f7 100644 --- a/infra/cron/pw-hc-campaign +++ b/infra/cron/pw-hc-campaign @@ -10,4 +10,4 @@ # Deliverability guard: warmup only mails SLIGHTLY-overdue providers (1-90 days # by default, HC_OVERDUE_MIN/MAX) -- recently-lapsed practices still have live # inboxes; heavily-overdue ones likely bounce and burn the warming IPs. -0 7 * * 1-5 deploy cd /opt/performancewest && HC_VERIFIED_CSV=/opt/performancewest/data/hc_warmup_nongoogle.csv python3 scripts/build_healthcare_campaigns_cron.py --start-campaign >> /opt/performancewest/logs/pw-hc-campaign.log 2>&1 +0 7 * * * deploy cd /opt/performancewest && HC_VERIFIED_CSV=/opt/performancewest/data/hc_warmup_nongoogle.csv python3 scripts/build_healthcare_campaigns_cron.py --start-campaign >> /opt/performancewest/logs/pw-hc-campaign.log 2>&1 diff --git a/infra/cron/pw-hc-nppes b/infra/cron/pw-hc-nppes index b2f444e..7f3988c 100644 --- a/infra/cron/pw-hc-nppes +++ b/infra/cron/pw-hc-nppes @@ -1,6 +1,6 @@ -# NPPES institutional general-compliance warmup base (63k verified, MX-throttled). -# The reval segments (pw-hc-campaign) run at 07:00 from the small fresh-past-due -# file; this runs at 07:30 from the large verified NPPES institutional base into -# the OIG/general-screening segment, throttled PER MX OPERATOR so volume spreads -# across receiving systems instead of hammering one. Weekdays only. -30 7 * * 1-5 deploy cd /opt/performancewest && HC_VERIFIED_CSV=/opt/performancewest/data/hc_nppes_institutional_verified.csv HC_SEGMENTS=oig_screening python3 scripts/build_healthcare_campaigns_cron.py --start-campaign >> /opt/performancewest/logs/pw-hc-nppes.log 2>&1 +# Healthcare NPPES institutional campaigns. Runs weekdays 07:30 from the large +# SMTP-verified + revalidation-enriched institutional base. Broad offers +# (OIG screening, NPPES data update) address the full ~62k verified pool; +# the revalidation segments target the ~1,400 genuine Medicare enrollees. +# Per-MX-operator throttled so volume spreads across receiving systems. +30 7 * * * deploy cd /opt/performancewest && HC_VERIFIED_CSV=/opt/performancewest/data/hc_nppes_institutional_enriched.csv HC_SEGMENTS=oig_screening,nppes_outdated,revalidation_overdue,revalidation_due_soon python3 scripts/build_healthcare_campaigns_cron.py --start-campaign >> /opt/performancewest/logs/pw-hc-nppes.log 2>&1 diff --git a/scripts/build_healthcare_campaigns_cron.py b/scripts/build_healthcare_campaigns_cron.py index 3e716c4..8418ff5 100644 --- a/scripts/build_healthcare_campaigns_cron.py +++ b/scripts/build_healthcare_campaigns_cron.py @@ -124,7 +124,8 @@ def warmup_day() -> int: def daily_slice(day: int) -> int: """TOTAL new subscribers to import across ALL segments today, aligned with the hc ramp. The rampcap caps hourly *delivery*; this caps daily *queueing* - so we never flood the warming IPs. Mon-Fri only (cron enforces weekday).""" + so we never flood the warming IPs. Runs DAILY (continuous warmup -- mailbox + providers reward consistent daily volume; weekends are NOT skipped).""" if day <= 1: return 100 if day <= 4: return 300 if day <= 9: return 600