Data Science in Your Product: A Practical Guide
Most companies sit on far more data than they use. It piles up in the database, gets graphed on a dashboard nobody opens, and otherwise does nothing. The interesting question is not “how do we analyze our data” but “how does our data make the product itself better for the person using it right now”. That shift, from reporting to features, is where data science earns its keep, and it is also where product owners get lost, because “add data science” is a request with no shape. This article gives it one: what the phrase actually means, the decisions that determine cost and risk, how to know whether it worked, and the cases where a rule you could write on a napkin beats any model.
What “adding data science” means for a product owner
Strip away the vocabulary and every data feature is the same object: a decision the product currently makes by a fixed rule, by a human, or by not making it at all, which you want to make better using history. “What do we show this user next”, “how many units do we order”, “is this transaction suspicious”, “which support ticket goes to the front of the queue”. A dashboard tells you something; a feature does something for the user. The same purchase history that fills a revenue chart can instead power a “you might also like” row that lifts sales. The same usage logs that show churn can trigger a timely nudge that prevents it.
Framing it as a decision does three useful things. It names the metric (what does “better” mean: more conversions, fewer stockouts, less fraud). It names the input (what do we know at the moment the decision is made). And it exposes the baseline, which is whatever the product does today. A model that cannot beat the baseline is not a feature, it is a cost.
The test for any data feature: does it change what the user sees or does, in the moment, for the better, and can you measure it against what happened before?
The patterns that move metrics
Nearly every product data feature is one of five shapes, and knowing which one you are building tells you most of what it will cost.
- Recommendation and ranking: which items, articles or actions to surface, in what order. The classic revenue win; also the one most sensitive to feedback loops, because the model only sees what it chose to show.
- Forecasting: turning history into a number about the future. Demand next month, delivery time, when inventory runs out. Useful, and the easiest to evaluate, because the future arrives and grades you.
- Classification and scoring: is this fraud, is this lead worth a call, will this user churn. Almost always deployed as a threshold on a probability, and the threshold is a business decision, not a data-science one.
- Anomaly detection: watching a stream and flagging what does not fit. A sensor failing, a metric falling off a cliff, a login from nowhere. Often the highest value per line of code, and the noisiest if tuned badly.
- Segmentation: grouping users by real behavior instead of guesses, so messaging and features adapt to each group. The least glamorous and frequently the fastest to ship.
Note what is not on the list: language models. Generative AI is its own category with its own economics, and we cover it separately in how to add AI to your app. The patterns above are older, cheaper, and for structured business data usually more accurate.
When a rule beats a model
This is the section product owners most need and vendors least want to write. A model is worth building when the relationship between inputs and the right answer is real, stable, and too complex to write down. When it is simple, a rule wins on every axis: it is explainable, testable, free to run, and it does not drift. “Flag any order over five times the customer's average” catches a large share of what a fraud model would catch, ships in an afternoon, and a support agent can explain it to an angry customer. Several honest signs you should start with a rule:
- A domain expert can describe the decision in a few sentences. Encode the sentences first; the model, if it ever comes, learns the exceptions.
- You have fewer than a few thousand labeled examples of the outcome. Below that, most models mostly memorize.
- The decision must be explained to a regulator, an auditor, or a customer. A rule is its own explanation.
- The cost of a wrong answer is asymmetric and high. A rule fails predictably; a model fails creatively.
- The data changes shape often. A rule is edited; a model is retrained, revalidated and redeployed.
The pragmatic path is a ladder: rule, then a simple model that only has to beat the rule, then a more capable one that only has to beat that. Every rung is shippable, and you stop at the first one whose gain no longer pays for its upkeep. The teams that skip to the top of the ladder build impressive models on a shaky foundation and cannot explain why the predictions are off.
Offline versus online inference
The second decision that shapes cost is when the prediction is computed. Two options, and most products should start with the first.
| Dimension | Offline (batch) | Online (real-time) |
|---|---|---|
| When predictions are made | On a schedule (nightly, hourly), written to a table | On request, per user action, from a served model |
| What the product reads | A precomputed column: churn score, recommended items | A live API response |
| Freshness | As old as the last run | Seconds, includes what the user just did |
| Infrastructure | A cron job and your existing database | A model server, latency budget, autoscaling, monitoring |
| Cost profile | Cheap and predictable | Scales with traffic; a slow model slows the product |
| Failure mode | Stale predictions, easy to detect | Timeouts on the critical path, needs a fallback |
| Good fit | Churn risk, reorder points, weekly recommendations, segments | Fraud at checkout, search ranking, session-aware suggestions |
Batch inference is underrated because it feels less impressive, yet a “likely to churn” column recomputed nightly and read by an ordinary query delivers most of the value of a real-time score at a small fraction of the operational burden. Go online only when the decision genuinely depends on what happened in the last few seconds, and when you do, define the fallback first: what the product shows if the model does not answer within its latency budget. The fallback is usually the rule from the previous section, which is one more reason to have built it.
Evaluation: how you know it worked
There are two evaluations and teams routinely confuse them. Offline evaluationasks whether the model predicts held-out history well: accuracy, precision and recall for classifiers, error magnitude for forecasts, ranking quality for recommenders. It is necessary, and it is where the classic mistakes live: training and testing on overlapping data, or letting a feature leak the answer (a “days since cancellation” column predicts churn perfectly and is useless). Split by time, not at random, because the product will always be predicting the future from the past.
Online evaluation asks the only question the business cares about: did the metric move? A model can score beautifully offline and change nothing in production, because users do not behave like a test set. The standard tool is an A/B test with the new decision against the baseline, held long enough to cover a full weekly cycle, measured on the metric you named at the start. If you cannot run an experiment, at minimum ship to a slice of users and compare. A feature that cannot be measured cannot be defended at the next budget review, and it should not be built.
# The evaluation that matters is against the baseline, on a time split
train = events[events.date < "2026-06-01"]
test = events[events.date >= "2026-06-01"] # never shuffle; the future is the test
rule_precision = precision(rule(test), test.label) # the napkin rule
model_precision = precision(model.predict(test), test.label)
# Ship only if the model beats the rule by more than its cost to run and maintainGarbage in, garbage out, for real
A model is only as good as the data behind it, and most real-world data is messy: missing fields, duplicates, inconsistent formats, events logged wrong or not at all. Before any modeling you need reliable collection, sane storage and cleanup, and that is most of the work. If a decision depends on a signal you do not currently record, the first deliverable is not a model, it is instrumentation plus a few months of waiting. Two habits pay for themselves: log the decision the product made and what happened next, so every feature generates its own training data, and keep the raw events, not just the aggregates, because the question you will want to answer next year is one you have not thought of yet. This is the same discipline that makes a multi-tenant database trustworthy: boring correctness first.
What it costs, honestly
The build is the smaller number. A first batch model on clean data is a few weeks of work; a rule is days. The lasting costs are elsewhere: the instrumentation to get the data, the pipeline that keeps it clean, the monitoring that notices when the model quietly stops being right, and the retraining when it does. Models drift: user behavior shifts, a marketing campaign changes who signs up, a supplier changes lead times, and a model trained on the old world confidently predicts it. Budget for someone to look at the accuracy numbers monthly and for a retrain every quarter or two, and for real-time serving add the infrastructure line. If those recurring costs exceed the gain the experiment measured, the rule was the right answer all along, and finding that out cheaply is a success, not a failure.
A decision framework you can run in an afternoon
- Which decision, and what is the baseline? Name the product decision and how it is made today.
- Which metric moves if it improves? If you cannot name one, stop here.
- Can an expert write the rule? Ship that first; it is the model's fallback either way.
- Do we have the data, labeled, at the moment of the decision? If not, instrument and wait.
- Batch or real-time? Batch unless the last few seconds change the answer.
- How will we test it against the baseline? Time-split offline, then an experiment online.
- Who watches it next quarter? Drift is certain; assign the owner before launch.
Where to start
Pick one decision in your product that is currently a guess, make data inform it, keep the first version simple, wire it into the actual experience, measure whether the metric moved, and iterate. That is how data stops being exhaust and starts being an advantage. Data features are part of the AI and data work we do, and they usually begin as one component of a larger platform. If you want help turning the data you already have into product features, and an honest opinion on whether you need a model at all, talk to us, or see what we have built.
Frequently asked questions
What does adding data science to a product actually mean?
It means taking a decision the product currently makes with a fixed rule, a human, or not at all, and making it better using history: what to show a user next, how much stock to order, whether a transaction is suspicious, which ticket goes first. Framing it as a decision names the metric that should move, the inputs available at the moment of the decision, and the baseline, which is whatever the product does today. A model that cannot beat the baseline is a cost, not a feature.
When is a simple rule better than a machine learning model?
When a domain expert can describe the decision in a few sentences, when you have fewer than a few thousand labeled examples, when the decision must be explained to a regulator or a customer, when a wrong answer is expensive and asymmetric, or when the data changes shape often. A rule is explainable, testable, free to run and does not drift. The pragmatic path is a ladder: ship the rule, then a simple model that only has to beat the rule, and stop at the first rung whose gain no longer pays for its upkeep.
What is the difference between batch and real-time inference?
Batch inference computes predictions on a schedule, for example a nightly churn score written to a database column that the product reads with an ordinary query. It needs only a cron job and your existing database and fails in obvious ways. Real-time inference computes a prediction per request from a served model, which is necessary when the decision depends on what the user did in the last few seconds, such as fraud at checkout or search ranking, but it adds a model server, a latency budget, autoscaling, monitoring and a fallback for when the model does not answer in time. Most products should start with batch.
How do you evaluate whether a data feature worked?
Twice. Offline evaluation checks whether the model predicts held-out history well, using a split by time rather than at random, because the product will always predict the future from the past, and watching for features that leak the answer. Online evaluation is the only one the business cares about: an A/B test of the new decision against the baseline, run long enough to cover a full weekly cycle, measured on the metric named at the start. A model can score beautifully offline and change nothing in production.
What does it cost to keep a model in production?
The build is the small number; a first batch model on clean data is weeks and a rule is days. The lasting costs are instrumentation to collect the data, the pipeline that keeps it clean, monitoring that notices when accuracy quietly degrades, and retraining when it does, because user behavior, marketing campaigns and supplier lead times all shift under a model trained on the old world. Budget a monthly look at accuracy and a retrain every quarter or two, plus serving infrastructure if the model runs in real time.
Is this the same as adding AI to my app?
Not quite. Recommendation, forecasting, classification, anomaly detection and segmentation are older, cheaper techniques that work on structured business data and are often more accurate for it than a language model. Generative AI is its own category with its own economics, which we cover in a separate guide on adding AI to your app. Many products need both, and the data discipline described here, clean events, a named metric and an honest baseline, is what makes either one measurable.
Thinking about building this?
Appluex designs and ships production mobile & web apps. Including AI features. Let's talk.