You operate an analytics database, and suddenly you notice a cohort of users that seem to never sleep, never take breaks, and generate SQL queries like there’s no tomorrow. You might ask: Are we getting DDoS’d again? The answer is no. It turns out that the company just deployed a fleet of autonomous AI agents that are tasked with monitoring and optimizing some business metrics.
If you’re in charge of a database or someone who designs database systems, that probably sounds both exciting and terrifying at the same time.
AI agents are rapidly evolving, gaining reasoning abilities combined with connectivity to 3rd party systems like real-time databases. With 2025 already labeled as the “agentic revolution” year, this post explores AI agents at the intersection of real-time analytics: how agents interact with data, their usage patterns, and what it means for real-time database design. We’ll take a look at AI agents as a “new user persona” for real-time databases and explore initial themes about how systems can adapt to their workloads. Finally, we’ll explore an example of a real-time analytics agentic workflow by demonstrating the ClickHouse MCP Server.
Google Trends Interest over time for “AI agents” in 2024
The next section will introduce definitions and background about the recent developments of AI. It will be useful in the rest of the post, but if you are already familiar with AI concepts (and have managed to keep up with the hype!), then I recommend skipping straight to the section Real-time analytics for AI agents.
ELI5 stands for “Explain Like I’m Five”, inspired by the subreddit r/explainlikeimfive
One can think of AI agents as digital assistants that have evolved beyond simple task execution (or function calling): they can understand context, make decisions, and take meaningful actions toward specific goals. They operate in a “sense-think-act” loop (see ReAct agents), processing various inputs (text, media, data), analyzing situations, and then doing something useful with that information. Most importantly, depending on the application domain, they can theoretically operate at various levels of autonomy, requiring or not human supervision.
The game changer here has been the advent of Large Language Models (LLMs). While we had the notion of AI agents for quite a while, LLMs like the GPT series have given them a massive upgrade in their ability to “understand” and communicate. It’s as if they’ve suddenly become more fluent in “human” aka. able to grasp requests and respond with relevant contextual information drawn from the model’s training.
These agents can have superpowers through their access to “tools”. Tools enhance AI agents by giving them abilities to perform tasks. Rather than just being conversational interfaces, they can now get things done whether it’s crunching numbers, searching for information, or managing customer communications. Think of it as the difference between having someone who can describe how to solve a problem and someone who can actually solve it.
For example, ChatGPT is now shipped by default with a search tool. This integration with search providers allows the model to pull current information from the web during conversations. This means it can fact-check responses, access recent events and data, and provide up-to-date information rather than relying solely on its training data.
ChatGPT’s search tool UI
Tools can also be used to simplify the implementation of Retrieval-Augmented Generation (RAG) pipelines. Instead of relying only on what an AI model learned during training, RAG lets the model pull in relevant information before formulating a response. Here’s an example: Using an AI assistant to help with customer support (e.g. Salesforce AgentForce, ServiceNow AI Agents). Without RAG, it would only use its general training to answer questions. But with RAG, when a customer asks about the latest product feature, the system retrieves the most recent documentation, release notes, and historical support tickets before crafting its response. This means that answers are now grounded in the latest information available to the AI model.
Thinking before speaking sounds like a smart thing to do, doesn’t it?
Another development in the AI space, and perhaps one of the most interesting, is the emergence of reasoning models. Systems like OpenAI o1, Anthropic Claude, or DeepSeek-R1 take a more methodical approach by introducing a “thinking” step before responding to a prompt. Instead of generating the answer straightaway, reasoning models use prompting techniques like Chain-of-Thought (CoT) to analyze problems from multiple angles, break them down into steps, and use the tools available to them to gather contextual information when needed.
This represents a shift toward more capable systems that can handle more complex tasks through a combination of reasoning and practical tools. One of the latest examples in this area is the introduction of OpenAI’s deep research, an agent that can autonomously conduct complex multi-step research tasks online. lt processes and synthesizes information from various sources, including text, images, and PDFs, to generate comprehensive reports within 5 to 30 minutes, a task that would traditionally take a human several hours.
A simplified AI timeline
If you need to spend more time on AI definitions, I recommend this great video about AI agents from IBM.
Alright, so it’s 2025 and we have LLM-powered AI agents that can perform tasks at various degrees of autonomy, and can access external tools to run queries, gather information, or execute actions.
Now let’s take the case of an agentic AI assistant with access to a real-time analytics database containing the company’s CRM data. When a user asks about the latest (up-to-the-minute) sales trends, the AI assistant queries the connected data sour