One Year of Chat DIC: Basic SQL’s November EXPLAIN Pass Rate Reaches 100%, and Validated-Query Pro Is Introduced

SK PlanetSK Planet·Original
Operator Bae ChangHyun

Key point

The AI Data Platform team added an approval-based Pro and raised the November EXPLAIN pass rate for Basic SQL audits to 100%.

1 / 16

Details

  • The AI Data Platform team spent a year improving Chat DIC for SK Planet’s Hadoop-based enterprise data platform, DIC, and added Pro to Basic, which focuses on SQL guidance; Pro provides validated query execution and result interpretation.
  • The rate of syntax and parsing errors in SQL generated by Basic was 31.8% through July, then fell to the 7% range in September after guide checks and retries during generation. After the Hadoop 3 migration, adding the new paths to the metadata dictionary brought the EXPLAIN-based success rate for November user SQL audits to 100%.
  • The number of members who used Chat DIC at least once grew from 30 to 193, and the data connected to Pro expanded from 7 datasets to 58.

Basic Search and Quality Management

  • Basic supports table search, SQL generation, and tuning, while users execute SQL in a separate tool. For privacy and regulatory reasons, people must query source data in a controlled, isolated network.
  • Supervisor splits up metadata search and SQL generation and validation, regenerating SQL for a question according to internal guidelines up to 3 times. Search combines semantic search and BM25 results with RRF, incorporates importance as a weight, and limits reranking candidates to a maximum of 100.
  • A fixed 104-question regression evaluation runs whenever the prompt, model, or code changes, and it currently has a 100% pass rate. After deployment, actual SQL is checked weekly, but passing Hive EXPLAIN does not guarantee the accuracy of the results.

Pro Execution Controls and Performance

  • Pro executes only SQL that has been validated by a person and obtains user approval before execution. The agent passes a query ID and arguments to a safe-query retrieval MCP in a separated network, the code calculates the figures, and the model interprets the results.
  • After changing the search to look up queries for the relevant app first using app tags, input tokens decreased by 21.5% and the number of candidates by 28.6%. Queries spanning multiple months were also bundled into date-range queries, reducing the number of approvals from 4 to 1.
  • Introducing internally operated Trino and Iceberg reduced the time for major queries to one-tenth or less. Cohort analyses and other queries that took more than 4 minutes are pre-aggregated by reference month in Airflow.

Context Limits and Next Steps

  • The original query results are stored in MongoDB, and only the columns, total row count, first 5 rows, and reference IDs are passed to the model, reducing the input for a new question to about 30,000 tokens; it continued to work normally after 11 turns.
  • However, on the 18th turn of an actual conversation in October, each of the 3 model calls carried 750,000–800,000 tokens, and the turn’s total of 2.36 million tokens was 46 times the usual roughly 50,000 tokens. The limit was not exceeded, but the input burden on subsequent turns was also high.
  • The author gave subjective estimates of quality contributions—not measured values—of 40% for the dictionary and data, 35% for evaluation and operations, and 15% for the LLM, adding that the LLM’s actual contribution was closer to 20%. The team is considering running simple aggregates without personal information in Basic, as well as a classification engine to determine Basic vs. Pro routing and assess personal-information exposure.

This summary was generated automatically by AI. Check the original for the author's claims and context. Copyright belongs to the original author.

Our guide explains how the AI works. Report summary errors, attribution issues, or removal requests via Contact.