From Spreadsheet Review to Agentic Oversight: Rearchitecting Pricing Compliance at Scale.
A RAG + MCP tool layer and Monte Carlo anomaly engine that cut analysis cycle time 70%+ and sustained 99.9%+ accuracy across 1,000+ pricing deployments on a $20B+ lending portfolio.
Context
SoFi's lending business spans Personal Loans, Student Loans, Credit Cards, and Home Loans — each with its own pricing grid, experiment cadence, and regulatory surface area. A single quarter can ship hundreds of grid revisions and A/B configurations, every one of which must stand up to OCC exams, Internal Audit, and 2LOD review.
As Senior Data Scientist owning the compliance and operations analytics roadmap, my mandate was clear: move the function from reactive, spreadsheet-driven review to proactive monitoring that could keep pace with a $20B+ portfolio without sacrificing auditability.
Business Problem
“Review cycles measured in days don't survive a pricing cadence measured in hours. The bottleneck wasn't intelligence — it was context-switching across grids, experiments, and eval tables that lived in six different places.”
The legacy workflow required analysts to manually diff pricing grids, reconcile experiment metadata, and assemble WAC and approval-conversion-loss trade-offs by hand before each deployment. That meant every grid change paid a tax in cycle time, and every regulator request paid a tax again in retrieval. The cost wasn't just analyst hours — it was deployments delayed, anomalies caught late, and a narrowing ability to run the experimentation the business actually needed.
- Audit-Readiness Gap
- Cycle-Time Drag
- Late Anomaly Detection
- Experiment Throughput Ceiling
The Senior Approach
The senior call was to treat this as two adjacent problems, not one. Compliance monitoring needed continuous, deterministic detection — Monte Carlo anomaly checks over near-real-time pricing telemetry. Analyst workflow needed leverage — a RAG + MCP tool layer that let LLMs safely interrogate the pricing artifacts, experiment metadata, and evaluation tables that already existed in Snowflake. Neither half works without the other.
Governed Data Layer
Built automated Python/SQL/dbt pipelines processing millions of application records daily — the audit-grade substrate every downstream tool would read from.
MCP Tool Layer
Wrapped pricing grids, experiment metadata, and evaluation tables behind a secure MCP interface so LLMs could answer 'Grid A vs Grid B' and 'Experiment 1 vs Experiment 2' diff questions without leaking data.
Monte Carlo Alerting
Deployed anomaly detection across Personal, Student, Credit Card, and Home Loan pricing flows — catching deployment drift in near real time instead of at audit time.
Realistic System Architecture
Representative MCP Tool Surface
# Grid diff tool exposed to the LLM via MCP.
# The LLM never touches raw Snowflake — it calls tools
# that enforce row-level auth and return governed shapes.
@mcp_tool(name="grid_diff", auth="pricing_analyst")
def grid_diff(grid_a: str, grid_b: str, product: Product) -> GridDiff:
base = load_grid(grid_a, product) # dbt-governed
cand = load_grid(grid_b, product) # dbt-governed
diff = compare_tiers(base, cand)
perf = pull_perf_windows(grid_a, grid_b, product)
return GridDiff(
tier_deltas=diff,
approval_conv_loss=perf.acl_tradeoff(),
wac_drift=perf.wac_drift(),
audit_trail=perf.lineage, # every number is sourced
)Outcome & Senior Judgment
The Impact
Key Takeaways
- 1
Tooling beats headcount when the bottleneck is retrieval.The cycle-time win didn't come from smarter analysts — it came from making the right pricing artifacts trivially reachable by both humans and LLMs.
- 2
Governance is a feature of the tool layer, not a review step.By enforcing row-level auth and lineage inside MCP tool wrappers, every LLM-generated answer arrived audit-ready by construction.
- 3
Proactive monitoring changes the conversation with regulators.Moving from post-hoc review to Monte Carlo anomaly alerting turned OCC and 2LOD interactions from discovery exercises into confirmation ones.