{
  "id": 19536865,
  "title": "The Semantic Debt Trap: Why AI Cannot Query Your Raw Data Lakehouse",
  "url": "https://urgent.news/2026/11/11/the-semantic-debt-trap-why-ai-cannot-query-your-raw-data-lakehouse",
  "topic": "ai",
  "section": "AI",
  "published": "2026-11-11T19:01:20.000Z",
  "source": {
    "name": "Dev.to",
    "slug": "dev-to",
    "url": "https://dev.to/abivarma/the-semantic-debt-trap-why-ai-cannot-query-your-raw-data-lakehouse-3a76"
  },
  "original_language": "en",
  "account": "Lakehouses store raw data, not business meaning. In a 2023 benchmark, GPT-4 with SQL generated only 16.7% correct answers to business questions on an insurance schema. Adding a knowledge graph improved accuracy to 54.2%, but still fell short on queries requiring multiple tables. Current AI models still struggle with concepts like polymorphic columns, join fan-out and varying business definitions, resulting in inaccurate SQL. The issue isn't technical skills, but semantic understanding. Three recurring problems: polymorphic columns yielding different totals, join fan-out causing inflated results and conflicting definitions of terms like \"active customer\" across departments. To address this, the article recommends three layers: raw lakehouse as storage, a versioned YAML semantic layer with YAML definitions reviewed in git, and an agent querying metrics by name through the dbt MCP server. The semantic layer scored 100% on 8 test questions, declining to guess on the 3 that required multi-hop reasoning. While not a foolproof solution, this approach prevents agents from writing raw SQL and instead relies on versioned semantic definitions. The article highlights that even with improved models, agents still struggle to compute metrics consistently without shared agreement on definitions. It suggests starting by having developers independently compute key metrics from raw tables - if they differ, an agent writing raw SQL won't perform better. Access to raw tables should be restricted to curated views or semantic-layer APIs only, with first five metrics defined in YAML and subject to review in git. The full article provides diagrams, benchmark details and a four-step readiness audit to assess data readiness for AI.",
  "summary": "Agents shouldn't write raw SQL against your lakehouse for any number that ends up in a board report. Your lakehouse holds your data. It doesn't hold what your business means by it. The benchmarks point the same way, with caveats. In a 2023 data.world benchmark (43 business questions on an insurance schema, zero-shot), GPT-4 writing SQL got 16.7% right. Through a knowledge graph of the same data…",
  "key_points": [],
  "editors_take": null,
  "illustration": null,
  "coverage": {
    "outlets": 1,
    "also_reported_by": []
  },
  "ai_generated": true,
  "disclaimer": "Summaries, key points and the editor’s take are written by software from other outlets’ reporting and may contain errors — always check the linked original."
}