kritwish.
  • Work
  • Systems
  • Playbook
  • Career

kritwish mondal, gtm engineer · diagrams sanitized: no customer data, no secrets

work / clean-data

Pillar 01 · Clean Data

A CRM people can trust again

Every report, routing rule and AI feature downstream inherits whatever the CRM gets wrong. This is the work that made it right, and the guards that keep it that way.

  • Salesforce
  • Apex
  • Flows
  • HubSpot
  • Postgres
  • SQL
  • Python

Why this had to be built

When the work started, 106 of about 16,000 leads had ever converted, 11,579 sat in “New” indefinitely, and Salesforce and HubSpot agreed on lead status only about 45% of the time.

Shipped

Salesforce rebuild

  • Salesforce
  • Flows
  • Bulk API 2.0
  • Python
  • HubSpot
the deep dive →

What it is

A rebuild of a Salesforce org that had stopped telling the truth: lead stages, conversion onto the right accounts, and the HubSpot sync.

What it did

  • ~4,800 leads converted onto the right accounts. Before, 106 of about 16,000 had ever converted.
  • 11,579 leads stuck in “New” reviewed against real evidence (replies, calls, meetings); 2,957 moved to the right stage with 0 failures.
  • Lead-status sync with HubSpot went from about 45% to 99.99%.
Before
106 of ~16k leads ever converted · sync ~45%
Action
Evidence-based re-staging, conversion onto matched accounts, sync repair
After
~4,800 converted · sync 99.99%
Verified by
Re-query of prod · sandbox flow tests 48/48
Production

Lead and account hygiene

  • Apex
  • Flows
  • Salesforce
  • LLM
  • ZeroBounce
  • HubSpot

What it is

Five automations that keep leads and accounts clean as they arrive: match every lead to the right account, name accounts properly, keep lead source meaningful, verify every email before anyone sends to it, and label every contact by seniority and function.

What it did

  • Lead-to-account matcher: a 200-lead trial, then 7,175 leads in 72 of 72 batches. Accounts went from 1,192 to 4,136, of which 2,944 were created automatically, with 0 duplicate domains. A check at conversion now stops reps creating duplicate accounts.
  • Account naming: auto-created accounts start out named after their domain. A 479-account backfill read each homepage and wrote 397 real names, all correct on a hand check; 83% needed no human touch.
  • Lead source: 32 legacy values consolidated to 7, set automatically on new records by flows and custom metadata.
  • Email verification: form fills were hard-bouncing at 2.7%. Every address now gets a SEND / DO NOT SEND / UNSURE verdict in both CRMs, cached for 90 days; a backlog of 8,597 was scoped down to the 2,942 that needed checking.
Before
1,192 accounts · leads unattached
Action
Trial of 200, then 7,175 leads in 72 batches
After
4,136 accounts
Verified by
Re-query: 0 duplicate domains
Production

Drift monitor

  • Postgres
  • SQL
  • Python
  • Cloud Run
  • Slack
the deep dive →

What it is

A nightly copy of 26 Salesforce objects into Postgres, every version kept, read by 56 SQL checks that flag anything drifting back toward the old mess.

What it did

  • 56 checks across leads, contacts, accounts and opportunities.
  • Results land on a console page with CSV export, and a Monday Slack alert lists only new problems.
  • Detect-only for now: it flags drift so it gets fixed the same week, rather than blocking it at the source.
Production

Suppression engine

  • Salesforce
  • Apex
  • HubSpot
  • lemlist
the deep dive →

What it is

One engine that decides who must never be emailed, and keeps Salesforce, HubSpot and the sequencer in agreement.

What it did

  • 1,247 leads and 4,704 contacts suppressed; 42/42 end-to-end tests.
  • When an automatic sync loop marked 150 leads Lost, all 150 were restored from field history and 741 bad suppression records were deleted.
  • The design changed so Salesforce can no longer unsubscribe anyone in the sequencer.
Incident
Sync loop marks 150 leads Lost
Action
Restore from field history · delete 741 bad records · cut the loop
After
150 of 150 restored
Guard
Design change: the loop can't recur
Next pillar →Pipeline

Want systems like these at your org?

Message me on LinkedIn