Skip to main content

How to Prepare Data for Natural Language Analytics

Emily Winks, Data Governance Expert, Atlan
Data Governance Expert
Updated:
|
Published:
11 min read

Key takeaways

  • Include only the tables those questions need.
  • A fluent wrong answer does more damage than an error message, because nobody checks it.
  • When an answer is wrong, find the missing piece of preparation instead of patching the prompt.
  • Preparation written as definitions, synonyms and verified SQL moves to the next tool.

How do you prepare data for natural language analytics?

To prepare data for natural language analytics, start from the questions people will ask, then give the tool a small set of clean tables whose metrics, joins, names, synonyms and example queries are written down in a semantic model. Add access rules and quality status to that data. Then test the setup against a fixed list of real questions before you open it to business users.

Is your AI agent context production-ready?


To prepare data for natural language analytics, start from the questions people will ask, then give the tool a small set of clean tables whose metrics, joins, names, synonyms and example queries are written down in a semantic model. Add access rules and quality status to that data. Then test the setup against a fixed list of real questions before you open it to business users.

Score One Question Before You Launch


Give it one business question people will ask in plain language and what you have on its definition, lineage, and access rules. It gates on the weakest dimension and returns the blocking gap. Read the skill.

Paste into a new chat

Use the skill at https://atlan.com/skills/ai-ready-question-score.md to score whether one business question is ready for natural language analytics. Ask me for whatever it needs.

Run once in a terminal

curl -fsSL --create-dirs \
  -o ~/.agents/skills/ai-ready-question-score/SKILL.md \
  https://atlan.com/skills/ai-ready-question-score.md

For an agent

curl -fsSL https://atlan.com/skills/ai-ready-question-score.md

What does natural language analytics need from your data?

The phrase covers two jobs. Most teams mean asking questions of structured data in plain words: “What was net revenue by region last quarter?” turns into SQL that runs on the warehouse. Some mean running NLP over text such as tickets or reviews. This page covers the first in full and the second in its own section.

For question answering, the language model already knows SQL. What it lacks is your business. It cannot know which of three revenue columns finance trusts, that “FL” means Florida, or that a fiscal year starts in February. Every tool asks you to write that knowledge down, and the formats are close enough that one piece of preparation work carries across them:

Tool Where the definitions live Business language you add Example and test assets
Snowflake Cortex Analyst A semantic view of logical tables, relationships, facts, dimensions and metrics Synonyms, descriptions and sample values per column Verified queries: questions paired with SQL
Databricks Genie Agents Unity Catalog tables, views and metric views, plus a knowledge store of measures, filters and joins Column descriptions, synonyms and entity matching Example SQL queries, SQL functions and benchmarks
Power BI Copilot The semantic model, with an AI data schema AI instructions Verified answers tied to trigger phrases

Snowflake states that semantic views are the recommended approach for new Cortex Analyst work. The same page now recommends moving to Cortex Agents, which calls Cortex Analyst over a semantic view for structured data, so the preparation carries over. Databricks notes that Genie Agents were formerly called Genie Spaces. For background on how these tools turn questions into answers, see what conversational analytics is.


Which steps prepare the tables themselves?

  1. List the questions, then scope to them. Collect the questions a named team asks today, with the answers they already accept. Include only the tables those questions need. The Azure Databricks guidance for Genie says to aim for five or fewer tables, against a hard limit of 50 tables, views or metric views per agent. An agent should serve “a particular topic and audience”, in that guide’s words.
  2. Shape the tables for questions. Pre-join related tables into views and hide columns that confuse or duplicate. Power BI’s Q&A modeling guidance gives the rule: each unique thing users talk about should be exactly one table or column. Union partitioned tables such as Sales2000-2010 and Sales2011-2020, split a Full Address column into its parts, and pivot property-bag tables into one column per property.
  3. Fix names and types. In Power BI’s Q&A guidance, a table called CustomerSummary forces users to ask about “customer summaries”. Rename it Customers. Dates and numbers imported as strings are not read as dates and numbers. Set Year, Month and ID columns to not summarize, so “total sales by year” does not also add up the years.

How do you teach the tool your business language?

Steps 4 to 6 write down the knowledge a new analyst would pick up in their first month.

  1. Define metrics, joins and filters once. Put “net revenue”, “active customer” and “large order” in the semantic model as code, not prose. Databricks recommends SQL expressions and example SQL over text instructions, and keeps text instructions as “a last resort”. If you model in dbt, the dbt Semantic Layer holds metrics in the project, so a changed definition “is refreshed everywhere it’s invoked”, and AI tools can read it through the dbt MCP server.
  2. Add descriptions, synonyms and real values. Users say “sales”, “bookings” and “revenue” for one column. Add those words as synonyms, and keep each synonym on one object only: Snowflake requires synonyms to be unique across the semantic model, and Power BI’s Q&A guidance warns that a synonym on several columns introduces ambiguity. Give the tool sample values for coded columns. Genie’s entity matching stores up to 1,024 distinct values for each of up to 120 columns, so “Florida” becomes WHERE state = 'FL' instead of a search that returns nothing.
  3. Write verified example queries. Pair your most common questions, phrased the way users phrase them, with SQL you have checked. Snowflake warns that “invalid or inaccurate queries can negatively impact” accuracy, and verified SQL must use the semantic model’s logical table and column names. Power BI offers the same idea as verified answers with trigger phrases.

Keep instructions short and consistent. If one instruction rounds to two decimals, every example query should too.


How do you keep access and quality right when anyone can ask?

  1. Put permissions and quality status on the data itself. Access has to hold at query time for every user. Cortex Analyst follows Snowflake’s role-based access control. In a Genie Agent, data access is evaluated with each user’s own Unity Catalog permissions, and row filters and column masks apply per user. Those controls interact with preparation: a table with a row filter is excluded from Genie’s prompt matching, and a masked column is left out of it. Plan sensitive columns before you build examples around them.

A fluent wrong answer does more damage than an error message, because nobody checks it. Before a table goes into scope, confirm it is fresh enough for the questions on your list, has a named owner, and carries a status that says whether it is approved. Genie Agents can be marked certified or deprecated through a governed tag, and Power BI models can be marked Approved for Copilot. For the full set of checks, see what trusted data for AI is and how to get it.


How do you test whether the data is ready?

  1. Score the setup against your question list, then keep scoring. The questions you collected at the start become your test set. Run each one, read the generated SQL, and compare the result with the answer the team already trusts. Databricks says to be the agent’s first user, save reviewed questions as benchmarks, and test variations in phrasing. Recruit business users only after the scores hold.

Expect variation between runs. Microsoft states that Copilot does not always produce the same response, even with the same input, and Databricks describes Genie as nondeterministic. One passing run proves little. Run each question several times and track the share of correct answers.

When an answer is wrong, find the missing piece of preparation instead of patching the prompt. A wrong join points to a missing metric or join definition. A missed term points to a missing synonym or sample value. A plausible answer from a stale table points to a missing quality check. Power BI’s “How Copilot arrived at this” view and Genie’s visible SQL both show what the tool used to reach an answer.

Re-run the test set whenever a schema, definition or policy changes. Plan for tool changes too: Microsoft says Q&A experiences go away in February 2027, with Copilot as the recommended path. Preparation written as definitions, synonyms and verified SQL moves to the next tool. Preparation hidden in one tool’s settings has to be redone.


What changes if your natural language analytics runs on text?

If the goal is to analyze text, such as support tickets, reviews or call notes, preparation looks different. Instead of semantic models, you prepare the text for a language model to read.

A common introduction to NLP lists four implementation steps: collect and preprocess text, convert it into numeric features such as vector embeddings, select and train a model, then evaluate and deploy it. The research paper Data Readiness for Natural Language Processing by Fredrik Olsson and Magnus Sahlgren (2020) frames the earlier work as identifying, making available, validating and preparing the data, based on projects with public and private organizations.

For classic NLP models, the same introduction lists the usual cleaning steps. Tokenization splits text into words or subword pieces. Stemming and lemmatization reduce words to their root form, and stop-word removal drops frequent words such as “the” and “a”. Removing punctuation, handling special characters and correcting spelling make the text consistent.

Teams often extract entities, topics or sentiment from text into columns, then let users ask questions of those columns in plain language. When that happens, the extracted columns need the same preparation as any table: clear names, a definition of each label, sample values and an owner who checks the extraction.


How does Atlan help prepare data for natural language analytics?

Atlan does the definition work once and hands it to each tool in that tool’s format. Atlan assembles a context repository for one use case from the governed context in your catalog and glossary. The docs call the repository “a portable semantic layer”: it renders as a semantic view for Snowflake Cortex Analyst, metric views for Databricks Genie and MetricFlow models for dbt, and agents that read it over MCP get the same definition without a deploy. A repository holds linked assets, such as tables, columns and glossary terms, and a semantic model you edit. The docs scope it to a job: “Answer pipeline questions for the sales ops team” is a use case, and “Sales” isn’t.

Quality status travels with the data. Vera, Atlan’s Data Quality agent, scores critical assets on completeness, accuracy and freshness, and those scores propagate along lineage to downstream assets and agents. Atlan MCP is a hosted server that serves this context to AI clients such as Claude, ChatGPT, Gemini and Copilot.

Workday shows why the order matters. Its first Talk to Data agent had “beautiful data on recurring revenue”, but when finance asked questions, the agent “couldn’t handle even the simplest ones”. In Atlan AI Labs workshops, “customers, including Workday, saw a 5x improvement in AI analyst response accuracy” after embedding metadata context through Atlan’s MCP server.


FAQs about preparing data for natural language analytics

Do you need a semantic layer for natural language analytics?


For anything beyond a few simple tables, yes. Without written definitions, the model guesses which column means revenue and how tables join, and it guesses differently on different days. A semantic model, a metric view or an AI data schema gives it one approved answer. Start with the metrics behind your most common questions and grow from there.

How many tables should a natural language analytics tool see?


As few as your question list needs. Guidance for Databricks Genie suggests five or fewer, with a hard limit of 50. Fewer tables mean fewer wrong joins and fewer columns with similar names. When a new team arrives with different questions, build a second, separate setup instead of widening the first one.

Who should prepare data for natural language analytics?


An analyst who knows both SQL and the business domain, working with the people who will ask the questions. The analyst writes the metrics, synonyms and example queries. Business users supply real questions and confirm the right answers. The data owner signs off on quality and access before the tool goes to a wider audience.

Is this the same as text preprocessing for NLP?


No. Text preprocessing cleans and converts documents, tickets or reviews so a model can analyze the words. Preparing data for natural language analytics makes structured tables answerable in plain language. The two meet when you extract labels or entities from text into columns, which then need names, definitions and sample values like any other column.


Sources

  1. Overview of semantic views, Snowflake Documentation
  2. YAML Specification for Semantic Views, Snowflake Documentation
  3. Cortex Analyst Verified Query Repository, Snowflake Documentation
  4. Cortex Analyst, Snowflake Documentation
  5. Cortex Agents, Snowflake Documentation
  6. Create and Manage a Genie Agent, Azure Databricks on Microsoft Learn
  7. Tune Genie Agent Quality, Azure Databricks on Microsoft Learn
  8. Curate an Effective Genie Agent, Azure Databricks on Microsoft Learn
  9. Prepare Your Data for AI to Improve Copilot Results, Power BI on Microsoft Learn
  10. Best practices to optimize Q&A, Power BI on Microsoft Learn
  11. dbt Semantic Layer, dbt Developer Hub
  12. An Introduction to NLP (Natural Language Processing), Technology vendor guide
  13. Data Readiness for Natural Language Processing, arXiv

Share this article

signoff-panel-logo

Atlan is the Context Layer for AI. It translates business knowledge, including data definitions, working procedures, and governance policies, into context AI can actually use. This knowledge lives in a single Enterprise Data Graph that every team and AI agent can reach.

In Atlan's AI Labs benchmark, adding this context improved AI's text-to-SQL accuracy by 38%.

Atlan is recognized as a Leader across multiple Gartner reports and Forrester Waves, and is trusted by over 400 enterprises representing $10T+ in market cap, including Mastercard, Workday, General Motors, CME Group, HubSpot, FOX, Virgin Media O2, and Elastic.

Bridge the context gap.
Ship AI that works.