Dinesh
D

Dinesh Kushwaha

Software Engineer

Building scalable solutions for complex problems.

dineshkushwaha.dev@gmail.com

Noida, Uttar Pradesh

Built with passion, coffee and code ❤️

Explore

  • Home
  • About Me
  • Skills
  • Experience
  • Projects
  • Contact

Services

  • Backend Development
  • REST API Development
  • Database Design
  • Microservices Architecture
  • DevOps & CI/CD
  • Cloud Deployment (AWS)

Resources

  • Coding Profile
  • Interview Preparation
  • Blog

Stay Updated!

Get notified when I publish new projects, case studies, blogs, or backend tutorials.

Your email is safe with me.

© 2026 Dinesh Kushwaha. All rights reserved.

Privacy Policy|Terms of Use

Case Study-IntelliImport

CSV -> CRM Lead Importer

AI-powered CSV → CRM lead importer. Upload any CSV layout, and batch AI extraction intelligently maps it to a standard CRM schema. Next.js + Express + Groq AI.

View Source Live Demo
0:00 / 0:00
★ Featured
Start Case Study

Project Overview

IntelliImport is an AI-powered import tool that turns any CSV, regardless of how its columns are named, into clean structured leads inside a CRM. A user uploads a file, reviews a preview, and confirms, and the system handles matching messy column names to the right schema automatically, with every AI mapping re-validated in code before anything is saved.

The Problem

Every lead source names its columns differently: Full Name versus Customer Name, Phone versus Mobile versus Contact. Hardcoded importers break the moment a new source shows up with a slightly different header. This surfaced from a real estate business where leads arrived from Facebook Ads, Google Ads, and agents typing walk-in leads into Excel. Every Monday, someone on the sales team manually merged all three files into the CRM by hand, matching columns row by row.

The Solution

IntelliImport splits the workflow into four real steps: upload, preview, AI mapping, and results. Parsing and previewing a file is free and instant, since no AI is called until the user explicitly confirms. Once confirmed, rows are sent to an AI model in small batches to guess the right column mapping, and every mapped field is checked against the CRM schema in plain code before it is trusted. Backend routes stay thin, only parsing requests and calling services, while all real logic such as CSV parsing, AI batching and retries, and schema validation lives in dedicated services with no knowledge of Express, which is what makes the AI provider and the database both swappable without touching a route.

Technology Stack

Frontend

Next.js 14TypeScriptTailwind CSSFramer Motion

Backend

Node.jsExpressTypeScript

AI

OpenAIGeminiClaudeGroq (swappable via one environment variable)

Database

PostgreSQLPrismaNeon (optional)

Hosting

Render (API)Netlify (Web)Neon (Database)

System Architecture

Upload

The client validates file type and size before anything is sent to the server.

Preview

The CSV is parsed and shown as a table. No AI is called yet, so this step costs nothing.

AI Mapping

Rows are sent to the AI provider in small batches, each one retried independently on failure.

Schema Validation

Every AI-mapped field is checked against the CRM schema in plain code before anything is saved.

Results

Imported and skipped rows are returned with reasons, searchable and paginated.

Key Features

Confirm-gated AI calls

AI only runs after the user explicitly confirms, so browsing or previewing a file never costs an API call.

Batch-level fault isolation

Rows are processed in small batches, so one malformed batch is skipped without failing the rest of the import.

Fail-fast on systemic errors

A dead API key or exhausted quota stops the import after the first batch instead of retrying and failing dozens of times.

Schema validation in code, not AI

AI only guesses column mappings. Every field is verified against the CRM schema in deterministic code before it reaches real data.

Swappable AI provider

OpenAI, Gemini, Claude, or Groq can be used interchangeably by changing a single environment variable.

Stateless by default

The importer works with zero database configured, and automatically starts persisting import history the moment one is connected.

Engineering Challenges

Challenge

Deciding how much to trust the AI with.

Approach

Early versions let the AI influence retry logic and light validation, not just column guessing.

Solution

Every decision that affects data correctness was pulled back into deterministic code. The AI only guesses what a column means, since that is the one part it is genuinely good at, and everything downstream is checked in plain code. That distinction mattered more than which AI provider was used.

Challenge

One bad row could take down an entire import.

Approach

The first version sent the whole file to the AI in a single request, so any malformed row anywhere in a 500 row file failed the entire batch.

Solution

Rows are now processed in small batches with isolated failure handling, so a bad batch gets skipped with a reason while the rest of the file keeps importing normally.

Challenge

Telling a bad row apart from a broken integration.

Approach

Retrying every failure the same way meant a dead API key caused the same slow, repeated retry loop as a single malformed row.

Solution

A distinction was added between row-level failures and systemic ones, so a dead key or exhausted quota stops the import after the first batch instead of quietly retrying and failing many times in a row.

My Technical Contributions

  • Designed and built the full import pipeline end to end: CSV parsing, AI batching and retries, and schema validation.
  • Built the provider-agnostic AI abstraction so OpenAI, Gemini, Claude, and Groq are all interchangeable behind one service.
  • Implemented batch-level fault isolation so a single bad row never fails an entire import.
  • Built the four-step frontend flow (upload, preview, processing, results) with a real URL for each step instead of hidden UI state.
  • Made the cost and reliability trade-off decisions behind the project, including gating AI calls behind explicit confirmation and validating every AI output in code before it touches real data.

Results & Impact

~2 hours to under 1 minute

Manual merge time saved

Weekly three-source lead merge that used to be done by hand.

1 bad batch, 0 failed rows

Import resilience

A malformed batch is skipped without affecting the rest of a large import.

4

AI providers supported

OpenAI, Gemini, Claude, and Groq, swappable with one environment variable.

Previous

WorkFlow

Next

CreadMatch