Skip to content
Back to featured work
Case Study | Flagship AI Product

Natural-language intelligence over private marketing data.

A multi-tenant analytics platform for enterprise B2B marketing teams, turning campaign and account data into governed NL-to-SQL analysis, attribution, forecasting, anomaly detection, reporting, and operator approval workflows.

11 enterprise B2B client accounts served by the platform
2.3M campaign and account data rows exposed through governed workflows
80+ REST endpoints across analytics, actions, approvals, and reporting
20+ AI features spanning chat, attribution, forecasts, and anomaly detection
Architecture

Local inference, strict tenant boundaries, and practical analyst workflows.

The product had to let operators ask natural-language questions over sensitive client data without creating cross-tenant leakage, runaway LLM spend, or unreviewed automated actions.

System flow

private data to governed actions

Data inputs

Campaign dataGoogle Ads, LinkedIn, Meta, DV360, Reddit Ads, StackAdapt.
Account dataABM, intent, budget, pipeline, and benchmark datasets.

Governed access

Tenant isolationLLM prompt constraints, SQL validation, and server-side WHERE injection.
API layer31 Python modules and 80+ REST endpoints across platform services.

AI reasoning

Local Qwen/Ollama7B model for SQL and narration; 1.5B model for classification.
Intent routingDATA, CHAT, WHY, OFFTOPIC, and ESCALATION paths.

Operator outputs

AnalyticsNL-to-SQL, attribution, forecasting, anomaly detection, and benchmarks.
ApprovalsConfidence-scored action queues, monthly reports, QBRs, and digests.

What I owned

  • Defined the product architecture, local model strategy, API boundaries, and tenant isolation model.
  • Built the NL-to-SQL chat layer with a 5-route intent classifier (DATA / CHAT / WHY / OFFTOPIC / ESCALATION), SQL validation, narration, and refusal paths.
  • Designed the analytics action layer: Markov-chain attribution via removal-effect analysis, a budget optimizer with marginal-efficiency and diminishing-returns estimation, what-if scenario simulator, forecasts, anomaly detection, anonymous cross-account percentile benchmarking, and confidence-scored approval queues for agentic auto-actions.
  • Implemented reporting automation: monthly HTML reports, QBR support, weekly digests, and video/voice briefing outputs.

Why it is better than a demo

The system had to handle private operational data, not toy datasets. The architecture reduced per-query LLM cost by keeping high-frequency analyst queries local, constrained all data access by tenant, and kept business actions behind approval queues instead of letting agents mutate live campaign state unchecked.

NL-to-SQL Qwen/Ollama FastAPI Multi-tenant SaaS AdTech Approval queues
Evidence

Proof points a hiring team can map directly to production applied AI.

System design

3-layer data isolation

Combined LLM system prompt constraints, SQL validation, and server-side WHERE injection to prevent cross-tenant leakage.

Cost control

Local inference for high-frequency use

Used a local Qwen/Ollama stack to eliminate per-query LLM cost while keeping sensitive data on-prem.

Product leverage

Analyst workflows, not raw model calls

Connected chat, attribution, simulations, forecasts, approvals, and reports into a usable operator workflow.

Need this kind of AI system in production?

I am strongest where model behavior, private data, product workflow, and delivery accountability meet.