What is agentic analytics?
Agentic analytics is data analysis carried out by an AI agent that plans its own steps: it looks up the schema, writes SQL, runs it, inspects the result and decides what to do next until it can answer the question. A person sets the question and the limits; the agent does the loop.
From one query to a loop
Text-to-SQL turns one question into one query. Agentic analytics wraps that in a loop with tools. Asked why revenue fell last week, an agent might read the orders schema, compare last week with the week before, find that one region accounts for most of the drop, break that region down by product, and check that the latest data has loaded before writing a summary. Each step depends on the previous result.
| Dashboard | Text-to-SQL | Agentic analytics | |
|---|---|---|---|
| Who decides the next query | The dashboard author, in advance | The user, one question at a time | The agent, from the last result |
| Typical output | Charts | A table of rows | An explanation with numbers and the SQL behind them |
| Main risk | Stale or missing views | One wrong query | Many queries: cost, data exposure, compounding mistakes |
What the agent needs
- Discovery: list catalogs, tables and columns without reading data.
- Meaning: what columns hold, in which unit, and how tables join. Names alone are often ambiguous.
- A way to run SQL with a bounded result, and to export large results instead of pasting them into the chat.
- Context on the data itself, such as data freshness, so it doesn't explain a drop that is really a late load.
These are usually exposed over the Model Context Protocol (MCP), an open protocol that lets assistants such as Claude, ChatGPT or Cursor call tools on a server.
Guardrails belong in the platform
A prompt that says "only run read-only queries" is a request, not a control. An agent that runs dozens of queries per question needs limits it cannot talk its way around:
- Credentials scoped to read, so a write fails whatever SQL the model produces.
- Cost limits per query and per day, checked before the query runs, not on next month's invoice.
- Row limits per call, so a SELECT * doesn't copy a table into a chat history held by the model provider.
- A log of every query with the user it ran for, so answers can be audited and reproduced.
Where it works and where it doesn't
Agents do well on exploratory questions over well-described data: which segment moved, whether a hypothesis holds. They do worse where a number's definition is a business decision, such as which orders count as revenue, unless that definition is written down where the agent can read it. Treat the answer like an analyst's first draft and read the SQL before acting on it.
In Thunderduck
Thunderduck runs a remote MCP server that Claude, ChatGPT and Cursor connect to with OAuth against your Thunderduck identity. Its tools cover discovery (get_catalog_context returns tables, keys, declared joins and column meanings in one call), queries, cost estimates, exports, query history and profiles, dbt pipelines including get_freshness, and scheduled jobs.
The limits are enforced by the platform. Token scopes decide whether an assistant can write at all. Every query is priced from its plan before it runs, with defaults of $5 per query and $50 per company per day, and a large external scan without a selective filter is refused regardless of price. Calls return 1,000 rows by default and 10,000 at most. In the console Assistant, actions that change something, such as running a pipeline, arrive as a pending card you approve.
Docs: https://docs.thunderduck.ai/ai/