Uploaded May 2026 | Updated September 2026, 6 hours ago
How do you let AI agents query billions of logs, metrics, and traces without melting their context window? Datadog's answer: hand them SQL.
This talk breaks down how giving AI agents direct SQL query access through the Datadog MCP server (Model Context Protocol) became the single biggest unlock for agentic observability and monitoring — and why LLMs running SELECT … COUNT … GROUP BY against web-scale data is now outperforming everything else they tried.
Reilly Wood, Staff Engineer at Datadog, walks through the real-world software engineering tradeoffs of building an MCP server for production AI agents. When customers first connected agents to Datadog, the data volumes blew past what any agent could reasonably process. Aggregation was the obvious need — but at web scale, no shortcut worked. The breakthrough was SQL. LLMs are trained on enormous amounts of SQL queries (Reilly argues they're better at it than most humans), and SQL turns out to play the same role for agentic data analysis that head and pipes play for Claude Code in bash: precise context window management through LIMIT, WHERE, and GROUP BY.
🔍 What's covered:
Why SQL beat every other aggregation approach for AI agents
Running queries at web scale with Trino (and evaluating DataFusion) — why Postgres alone won't cut it
Coaching agents through SQL dialect quirks (Postgres syntax with Datadog-specific variations)
Code execution vs. better-designed MCP tools — when each wins
A Claude Code anecdote: agent doing horrible raw-SQL string manipulation to work around a missing JSON function — and landing the right answer in two minutes flat
Why mapping existing REST APIs straight to MCP tools is a trap — design for token efficiency and context engineering instead
Advice for anyone building an MCP server for AI agents
🕒 Chapters:
0:00 Letting AI agents run SQL
0:21 Too much data for agents to handle
0:55 Web-scale queries with Trino and DataFusion
1:19 Datadog observability + agentic incident investigation
1:40 Why MCP plug-and-play matters
2:07 LLMs vs. SQL dialects
2:29 Code execution vs. better tools
3:32 The JSON parsing workaround
3:55 Anthropic as MCP steward
4:06 Advice for MCP server builders
The Datadog MCP server is in private preview now and opens to all customers in January.
🔗 Learn more: datadoghq.com
🔗 Search "Datadog MCP server" for the latest
If you're building AI agent infrastructure, agentic observability, or MCP servers on Claude, subscribe for more conversations with engineers doing it in production.
#MCP #ModelContextProtocol #Datadog #AIAgents #AIAgent #Observability #Monitoring #Claude #ClaudeCode #Anthropic #LLM #SQL #SQLQuery #DataAnalysis #SoftwareEngineering #DeveloperTools #AIEngineering #Trino #DataFusion #ContextEngineering #ObservabilityTools #AgenticAI
How do you let AI agents query billions of logs, metrics, and traces without melting their context window? Datadog's answer: hand them SQL.
This talk breaks down how giving AI agents direct SQL query access through the Datadog MCP server (Model Context Protocol) became the single biggest unlock for agentic observability and monitoring — and why LLMs running SELECT … COUNT … GROUP BY against web-scale data is now outperforming everything else they tried.
Reilly Wood, Staff Engineer at Datadog, walks through the real-world software engineering tradeoffs of building an MCP server for production AI agents. When customers first connected agents to Datadog, the data volumes blew past what any agent could reasonably process. Aggregation was the obvious need — but at web scale, no shortcut worked. The breakthrough was SQL. LLMs are trained on enormous amounts of SQL queries (Reilly argues they're better at it than most humans), and SQL turns out to play the same role for agentic data analysis that head and pipes play for Claude Code in bash: precise context window management through LIMIT, WHERE, and GROUP BY.
🔍 What's covered:
Why SQL beat every other aggregation approach for AI agents
Running queries at web scale with Trino (and evaluating DataFusion) — why Postgres alone won't cut it
Coaching agents through SQL dialect quirks (Postgres syntax with Datadog-specific variations)
Code execution vs. better-designed MCP tools — when each wins
A Claude Code anecdote: agent doing horrible raw-SQL string manipulation to work around a missing JSON function — and landing the right answer in two minutes flat
Why mapping existing REST APIs straight to MCP tools is a trap — design for token efficiency and context engineering instead
Advice for anyone building an MCP server for AI agents
🕒 Chapters:
0:00 Letting AI agents run SQL
0:21 Too much data for agents to handle
0:55 Web-scale queries with Trino and DataFusion
1:19 Datadog observability + agentic incident investigation
1:40 Why MCP plug-and-play matters
2:07 LLMs vs. SQL dialects
2:29 Code execution vs. better tools
3:32 The JSON parsing workaround
3:55 Anthropic as MCP steward
4:06 Advice for MCP server builders
The Datadog MCP server is in private preview now and opens to all customers in January.
🔗 Learn more: datadoghq.com
🔗 Search "Datadog MCP server" for the latest
If you're building AI agent infrastructure, agentic observability, or MCP servers on Claude, subscribe for more conversations with engineers doing it in production.
#MCP #ModelContextProtocol #Datadog #AIAgents #AIAgent #Observability #Monitoring #Claude #ClaudeCode #Anthropic #LLM #SQL #SQLQuery #DataAnalysis #SoftwareEngineering #DeveloperTools #AIEngineering #Trino #DataFusion #ContextEngineering #ObservabilityTools #AgenticAI










