r/dataengineering • u/renatyv • 23h ago
Personal Project Showcase Built two tools to help SQL agents understand unfamiliar databases
Stumbled upon these problems while doing the agentic pipeline
CREATE TABLEDDLs are not enough. To understand what's in the table you need to have basic per-column stats and see examples of rows- some tables (e.g., migrations, empty tables, old stuff, etc.) are useless for real analytics and real users, yet agent kept rediscovering them
- some tables only have less than 10 rows. Better see all rows instead of barebone column names and types
- some tables are huge, agent's queries were trying to get too much data. Good man won't query billions of rows
- agents needs to sample data from tables every time he researches a table
- if you have many columns, presenting data as a `transposed table` helps improve LLM's understanding
So I built two tools to solve these problems
- db-snooper: generates compact Markdown with schema, value distributions, and samples.
- schema-linker: finds possible undeclared joins and checks them against the data.
Full blog posts: db-snooper and schema-linker