Showing posts with label How to build a natural language query engine with LLMs. Show all posts
Showing posts with label How to build a natural language query engine with LLMs. Show all posts

Wednesday, July 29, 2026

Data Analytics advances in the age of LLMs

 

The rise of large language models is not only reshaping data engineering — it is fundamentally changing how we analyse data. For decades, analytics has been the domain of specialists writing SQL, building dashboards, and training models. Today, LLMs are turning that model on its head, enabling natural language interfaces, automated insight generation, and democratised analytics for everyone.

In this article, we explore the key advances that are powering the next generation of data analytics: from text‑to‑SQL and augmented analytics to automated data preparation and prescriptive recommendations. But we also take a hard look at the risks: over‑reliance on AI, data quality issues, and the organisational debt that can turn AI‑powered analytics into a costly failure.

✦ ✦ ✦

1. Natural language queries: the end of SQL as we know it?

One of the most visible impacts of LLMs on analytics is the ability to ask questions in plain English and get answers directly from data. Tools like ThoughtSpot, Power BI Copilot, and Snowflake Copilot are now using LLMs to translate natural language into SQL, MDX, or even Python — making analytics accessible to business users who never learned to code.

This is not just a convenience; it's a paradigm shift. The barrier to entry for data exploration has dropped dramatically. A product manager can now ask, “What were our top‑selling products last quarter in the EU?” and get a chart in seconds, without waiting for a data analyst.

Natural Language to SQL — querying with plain EnglishUser Query“Show me sales by region”LLMNLP → SQL(with schema awareness)Generated SQLSELECT region, SUM(sales) …Result / ChartInstant visualisationLLMs can generate SQL, but they also need context, schema, and validation to avoid errors.
Figure 1: LLMs bridge natural language and SQL, enabling self‑service analytics — but accuracy depends on data context and validation.

However, this power comes with risks. LLMs are notorious for hallucinating incorrect SQL, especially with complex joins or ambiguous schema. Data analysts still need to validate, optimise, and debug the generated queries. The skill of writing efficient SQL is not obsolete — it's evolving into a review and refinement role.

✦ ✦ ✦

2. Augmented analytics: AI‑powered insights

Beyond querying, LLMs are being used to automatically generate insights from data. This is often called augmented analytics — where AI suggests correlations, anomalies, trends, and even root causes without being asked. For example, an LLM might scan a sales dashboard and highlight that “Sales in the Midwest dropped 15% this month, driven by a decrease in repeat customers.”

This capability turns analytics from a pull (ask a question) to a push (get proactive alerts) model. It can save time, uncover blind spots, and help less technical users understand what's happening in their data.

Augmented Analytics — automated insight generationDataInsightEngine(LLM + statistical tests)Generated Insights• Sales dip in region X• Correlated with promo end๐Ÿ” Analyst validates, refines, and learns
Figure 2: Augmented analytics uses LLMs to proactively surface insights, but human validation remains essential.

The challenge is that these insights are only as good as the data and the model. Spurious correlations and misleading narratives can easily creep in. Therefore, organisations must still invest in data literacy and critical thinking — skills that AI cannot replace.

3. Automated data preparation and cleaning

Data scientists and analysts spend up to 80% of their time on data preparation — cleaning, transforming, and joining datasets. LLMs are now being used to automate many of these tasks. For instance, an LLM can suggest data type conversions, missing value imputation, or even generate Python/Pandas code to reshape a messy CSV.

Tools like Pandas AI, Trifacta, and Alteryx are integrating LLMs to recommend transformations based on natural language descriptions. This significantly speeds up the “data wrangling” phase, allowing analysts to focus on higher‑value work.

However, this automation is not foolproof. LLMs can misinterpret column semantics or apply transformations that introduce bias or data leakage. Again, the human in the loop must review, test, and document every step to maintain data integrity.

Automated CleaningMessy CSVLLM clean(impute, format)Clean dataset⚡ 80% time saved
๐Ÿงน Automated data prep
Feature EngineeringRaw featuresLLM suggest(new features)Enhanced set๐Ÿ’ก ML‑ready
⚙️ Feature suggestions
✦ ✦ ✦

4. Predictive and prescriptive analytics with LLMs

LLMs are not just for querying and cleaning; they are also being used to generate predictive models and prescriptive recommendations. For example, an LLM can take a dataset and suggest which machine learning model to use, or even write the training code. More advanced systems can explain model predictions in plain English, making AI more interpretable.

Prescriptive analytics goes a step further: the LLM can recommend actions based on predictions. For instance, if the model predicts a high churn risk, the LLM might suggest “Send a 10% discount coupon to these customers” and even draft the email copy.

This blurs the line between analytics and decision‑making. It also raises ethical concerns — who is accountable for automated decisions? Data analysts must become AI ethicists and risk managers as they deploy these systems.

“Prescriptive analytics powered by LLMs can drive business value, but they also require robust governance, transparency, and human oversight.”
✦ ✦ ✦

5. The double‑edged sword: LLMs and analytics skills

Just as in data engineering, the rise of AI in analytics carries the risk of skill erosion. When a chatbot can write SQL, generate a chart, or even build a model, what happens to the analyst's ability to think critically, understand data lineage, and question assumptions?

There is a growing concern that over‑reliance on LLMs will create a generation of analysts who can prompt but cannot debug. For instance, asking an LLM to “find the root cause of sales decline” might produce a plausible explanation, but without domain knowledge and statistical rigor, that explanation could be completely wrong.

Moreover, the search and synthesis skills that analysts traditionally develop by reading forums like Stack Overflow or academic papers are being bypassed. The act of struggling with a problem often leads to deeper understanding — and that struggle is being outsourced to a machine.

Analyst + LLM — collaboration or dependency?AnalystLLM(assistant)Insight / SQL(needs validation)⚠️ The analyst must retain
critical thinking, domain knowledge, and statistical literacy — AI is a tool, not a replacement.
Figure 5: The partnership between analyst and LLM is powerful, but over‑dependency can erode core skills.

The solution is to use LLMs as junior assistants — they generate drafts, suggest alternatives, and automate routine tasks. But the final validation, interpretation, and storytelling must remain human. This requires a deliberate effort to maintain analytical rigor and continue investing in training.

✦ ✦ ✦

6. The organisational and cultural reality of AI‑driven analytics

“If your company has never cared about clean data, then AI integration at scale will not be feasible without starting from the bottom and working up. If your company doesn’t have an engineering culture and you let people enter whatever they want into your CMS/financial system/whatever, then you’re not going to get what you expect out of AI.”

“The AI kool‑aid crazy has been getting smothered by research pointing out that AI shifts the workload in many cases, blunts talent in other cases — the outages, the dropped databases, and the financial losses. … Take something like generating takeoffs from engineering drawings and building price sheets. That’s not exactly pushing the limits of modern AI. But if your inputs are inconsistent, your pricing data is all over the place, and nobody owns the implementation, it’s almost guaranteed to fail.”

These words, echoed across many industries, highlight a painful truth: AI cannot fix broken data culture. Many organisations rush into AI‑powered analytics without addressing the fundamental hygiene of their data. Inconsistent formats, missing values, duplicate records, and poor documentation become amplified when fed into an LLM — leading to garbage‑in, garbage‑out at scale.

Moreover, the cultural shift required is often underestimated. Analysts and business users need to learn how to prompt effectively, interpret outputs skeptically, and take ownership of the final product. Without this, the organisation becomes dependent on consultants who build black‑box solutions that fail after they leave.

The financial risks are real. Millions of dollars have been wasted on AI projects that were poorly scoped, poorly governed, and poorly executed. The privacy concerns around feeding sensitive data to cloud‑based LLMs add another layer of risk. And the recent backlash against massive data center investments suggests that the ROI of AI is far from guaranteed.

For analytics leaders, the path forward is clear: invest in data governance, data literacy, and a culture of quality before deploying AI at scale. Treat AI as an accelerator, not a silver bullet. And always keep a human in the loop — because the most powerful insights are those that combine machine intelligence with human wisdom.

✦ ✦ ✦

7. The road ahead

As LLMs continue to evolve, we can expect even more advanced analytics capabilities:

  • Multi‑modal analytics: Combining text, images, and tables in a single query.
  • Autonomous agents: LLMs that can not only answer questions but also take actions (e.g., send emails, update dashboards).
  • Continuous learning: Systems that improve over time by incorporating feedback from users.
  • Explainable AI: LLMs that can provide detailed reasoning behind their suggestions, building trust.

But with these advances comes a greater need for responsible AI — ensuring fairness, transparency, and accountability. Analytics professionals will need to upskill in AI ethics, model governance, and change management.

The future of analytics: human + AIHuman Analystcuriosity, contextLLMscale, speed, automationBetterDecisionsThe partnership between analysts and AI will define the next decade of analytics.
Figure 6: The future is not AI replacing analysts, but AI empowering them to be more effective.
✦ ✦ ✦

The age of LLMs is ushering in a golden era for data analytics. Natural language interfaces, automated insights, and intelligent data preparation are making analytics more accessible, faster, and more powerful than ever before. But this power must be wielded with responsibility, critical thinking, and a strong foundation in data quality and governance.

As analysts, we must evolve from being query writers to insight curators and AI supervisors. We must embrace the tools, but never lose sight of the art and science of asking the right questions, interpreting results, and communicating narratives that drive action.

The organisations that will succeed are those that invest in people, processes, and culture — not just technology. They will treat AI as a force multiplier for human intelligence, not a replacement. And they will remember that the most important analytics skill is still curiosity.

Further reading:
How to build a natural language query engine with LLMs
The ROI of augmented analytics: case studies
Data governance for AI‑powered analytics

#DataAnalytics #LLMs #NLPtoSQL #AugmentedAnalytics #AIethics