Brownfield AI
AI data quality: how do you clean and deduplicate data?
Grounding an assistant in customer data starts with normalizing that data, one tenant at a time.
Short answer
Good AI data quality starts by cleaning and deduplicating messy data before adding AI: normalize it per source, then link records with explicit rules. Profile each feed, fix placeholders such as fake prices, split overloaded fields, map categories to one vocabulary, and decide which source wins when systems disagree. Only then add retrieval or prompts. AI data quality problems that reach the model come back as confident, wrong answers.
On this page
01Why customer data breaks AI answers
Google's machine learning course lists the usual causes of unreliable data: missing values, duplicate examples, bad values and wrong labels. Those problems hurt a trained model. They hurt an AI assistant even more directly, because the assistant repeats the bad value to a customer in fluent language. A placeholder price becomes a quoted price. A duplicate record becomes two recommendations for the same item. A wrong category sends a buyer to the wrong product. This is part of our larger guide, AI integration for SaaS.
Prompt work cannot fix this. You can tell a model never to invent prices, but if the feed says a unit costs one dollar, the model is not inventing anything. It is reading your data correctly. The fix has to happen before the data reaches the model.
02Profile every feed before you trust it
When customers supply the data, every tenant breaks the rules in its own way. Profiling each feed first shows you which rules it breaks. These are the problems we see most often, with the fix for each:

| Problem | Example | Fix | Where it runs |
|---|---|---|---|
| Placeholder values | A price of one dollar that means call for price | Treat as missing and show price on request | Ingestion rule per tenant |
| Missing values | No price at all | Exclude from price filters, keep in search | Ingestion |
| Duplicate fields | Two classification columns that disagree | Pick one source of truth per tenant | Mapping configuration |
| Mixed entity types | RVs and boats in one file | Split by type before indexing | Ingestion |
| Inconsistent links | Different listing URL schemes per dealer | A URL template per tenant | Configuration |
| Overloaded strings | Quantity, unit, item and preparation in one ingredient line | Parse into separate fields | Cleaning step |
| Branded names | A restaurant's own name for a common dish | Map to a generic name | Similarity matching |
The important column is the last one. Most fixes belong in per-tenant configuration, not in code branches and not in the prompt.
03An AI data quality pipeline that holds up
We build the pipeline in this order, and we do not skip ahead to the AI step:

- 01
Profile each source
counts, empty values, value ranges, duplicate keys and suspicious constants.
- 02
Normalize per tenant using configuration, so a new customer with a new quirk needs a mapping change, not a code fork.
- 03
Standardize vocabularies. Map categories, units and labels to one controlled list. In search engines such as Elasticsearch, a keyword normalizer applies the same cleanup both when data is indexed and
- 04
Resolve entities. Match records that refer to the same thing, merge them, and write survivorship rules that say which source wins when two systems disagree. Tools such as Splink do probabilistic linka
- 05
Link related entities, such as ingredients to recipes and recipes to menu items, so facts can be derived from the links instead of guessed.
- 06
Validate and report. Count rejected and corrected rows and report them back to the data owner, so they can fix the source.
- 07
Re-run on a schedule with change detection, because feeds change hourly and the fixes have to keep up.
04Where AI helps, and where it must not
AI is useful inside the cleaning pipeline. Language models can fill and standardize attributes such as company size or practice area. Similarity models can match a branded dish name to a generic one, or a long ingredient line to a clean ingredient. These are fuzzy language problems, and models handle them well.
Facts are a different matter. Prices, stock levels, nutrition values and account scores should come from linked, validated data, not from a model's guess. When nothing matches, the assistant should say so honestly rather than offer the closest thing as if it were an exact match. Keep a clear line between what the model may normalize and what it may never produce. For more on the gap between a working demo and production data, see why AI-generated code is not enough for brownfield SaaS.
05Exact matching does not scale
Comparing every record with every other record is too slow once you have millions of rows. The usual answer is to reduce the comparisons: turn names into numeric vectors, search with short word sequences, and use locality sensitive hashing so only likely matches are compared in full. The same blocking idea sits underneath probabilistic linkage tools. Plan for it early, because a matching step that works on a sample can stall on the full dataset.
06What we see in production
For a civic transparency platform, votes, bills, stock trades and campaign finance were all public, but spread across many government sites in different shapes, some of them scrape only, and every score had to be explainable to voters who might challenge it.
We designed the data model before any screen, built pipelines that link every vote, bill, trade and donation to the same representative and bill, and mapped the seats that district boundaries miss by hand. Each score shows how it was calculated and where its numbers come from, and AI summaries were planned only after the data was linked and checked against its sources.
For a food discovery and nutrition startup, the data arrived as several disconnected JSON databases of restaurants, menu items, recipes and ingredients. We cleaned and normalized first: generic names for branded menu items, clean categories, ingredient lines split into quantity, unit, item and preparation, and duplicate ingredients merged. Then we linked them, using word2vec, word sequence search and locality sensitive hashing to make similarity search over the large set several times faster. Nutrition values come from the linked recipe and ingredient data, not from a model.
For a B2B SaaS company serving professional firms, one of our engineers works inside the client's own Azure and Microsoft Fabric environment, with its internal team, on a master database of customers and prospects. The approach we proposed puts survivorship rules first, entity resolution before anything else, and then a pipeline that uses a language model to fill and validate firm attributes, with scoring tuned to the client's own retention, expansion and deal velocity signals. Clean master data first, AI scoring second. The client owns the platform, and everything is documented so its team can run it.
In that master data build, the account, contact and activity layers were designed in Azure SQL first, and Microsoft Fabric came in only after entity resolution held, so the lakehouse starts from resolved records and the Ideal, Emerging, Acceptable and Avoid tiers go back into Salesforce on one merged account each.
Frequently asked questions
Can prompt instructions fix bad data?
No. You can tell a model never to invent prices, but if the feed says a unit costs one dollar, the model is reading your data correctly. The fix has to happen before the data reaches the model, through ingestion rules, per-tenant configuration and cleaning steps.
Where should data fixes live?
Most fixes belong in per-tenant configuration, not in code branches and not in the prompt. A new customer with a new quirk then needs a mapping change, not a code fork. Placeholder values, missing values and mixed entity types are handled at ingestion, and overloaded strings in a cleaning step.
Should AI be used to clean data?
Yes, for fuzzy language problems. Language models can fill and standardize attributes such as company size, and similarity models can match a branded dish name to a generic one. Facts such as prices, stock levels, nutrition values and account scores should come from linked, validated data, never from a model's guess.
How do you deduplicate millions of records?
Reduce the comparisons instead of comparing every record with every other. Turn names into numeric vectors, search with short word sequences, and use locality sensitive hashing so only likely matches are compared in full. Plan for it early, because a matching step that works on a sample can stall on the full dataset.
How Datics helps
Datics specializes in Brownfield AI: production AI inside software people already rely on. A Build Sprint puts one outcome working in your product's staging in three weeks, for $10,000, and the fee counts toward production. Not sure what to build first? The Planning Sprint ranks it in two weeks, for $5,000.
Related work
Case studies from our projects on the same subject.
Coast Technology
Automotive · AI sales assistant for dealers
RV shoppers get units from live stock, with towing fit computed, not guessed
Dealer sites offered static forms and filters. Now shoppers ask in plain words and get real units from the hourly feed, with the reason each one fits.
Assembly Software
MarTech · Governed customer and prospect model
Assembly Software's scoring and reporting will stand on one governed record per account
The same account carried conflicting values in five systems. We are building one governed model inside Assembly's data team and its Azure.
Coast Technology
Automotive · Competitive inventory intelligence engine
Dealers see rival stock, prices and sales daily, captured from many changing websites
Dealers checked rival lots by hand, site by site. Now one engine captures competitor stock daily and the portal compares prices and sends alerts.
More on Brownfield AI
Brownfield AI
AI integration for SaaS: build AI into your live product
AI integration for an existing SaaS product: keep your core as the system of record, reuse your APIs and auth, and ship one AI workflow at a time.
Brownfield AI
Entity matching: how do you map supplier data to a catalog?
Entity matching for product data works when you agree on mapping rules first, normalize before you compare, and route uncertain matches to people.
Brownfield AI
How do you build an AI data pipeline from outside sources?
An AI data pipeline for outside sources needs a reviewed data model and ETL that links records to real entities. Learn how to plan sources and mappings.
Brownfield AI
How do you build an AI recommendation engine?
How to build an AI recommendation engine: define a good recommendation, fix the signals, share one index with search, and measure against a baseline.
Brownfield AI
How do you know if your product has AI ready data?
AI ready data means outside feeds arrive through logged pipelines that match, de-duplicate, validate and attribute records before any model sees them.
Brownfield AI
How does data quality monitoring catch bad AI inputs?
Data quality monitoring for AI features: watch input completeness per source and run, then block or flag statistics, dashboards and AI answers when it drops.
Your customers already expect AI from your product.
Let us make it real inside the product you run today.
