Venkateswara
Back to Vol. 1

VS.01 · Agentic AI · Retrieval · Jan–May 2026 · Eval Oct 2026

VS.01Chapter Tear-Down

F1InsightAI

vs. The Confident Wrong Answer

39 / 40 reference-result matches on a frozen 701,433-row F1 snapshot after replacing schema dumps and proxy metrics with enriched FAISS retrieval and independent grading.

Stack
Python · LangGraph · FAISS · TiDB Cloud · Groq Llama 3.3 70B · Flask · Docker
Throughput
9-node state graph · 701,433 frozen rows across 14 tables
Tolerance
39 / 40 (97.5%) exact result matches · MRR@7 0.678 → 0.888 · 5 / 5 fault probes
Known Limits
Authored 40-query single-domain F1 suite; live UI MRR is a generated-SQL proxy, not ground truth; live TiDB footer shows 701,694 rows (+261 vs. frozen snapshot).

Reference-result matches (97.5%)

39 / 40

First-attempt and final result-table equivalence against reviewed reference SQL on an isolated frozen MySQL snapshot

n: 40 separate authored SQL queries (after 20 dev queries)

Dense MRR@7 (plain → enriched)

0.678 → 0.888

Independent required-table relevance labels (0.678155 plain vs. 0.887500 enriched FAISS schema retrieval)

n: 40 evaluation SQL queries, identical embeddings and frozen snapshot

Injected invalid-column probes recovered

5 / 5

Forced invalid-column SQL faults routed through the error-guided reflection node

n: 5 controlled error-injection probes (zero implicit SDK retries)

VS.01 · Tear-Down PlateScroll Scrub · 0% Exploded
Monochrome ink illustration of a matte-black Formula 1 front wing over drafting sheets traced by a single crimson line
Illustration · Not system output
Monochrome ink illustration of a matte-black Formula 1 front wing over drafting sheets traced by a single crimson lineHalftone Wipe · 4:3 Uncropped

Give a language model fourteen Formula 1 tables and it writes SQL that looks right until you check the rows. Worse, our first evaluator graded the model against its own output. I audited the evaluator, froze the database, and graded forty queries against ground-truth result tables.

Panel 01 · The Dread (What Silently Breaks)

Dumping 14 relational tables into an LLM context invites hallucinated column names, broken multi-table joins, and silent read/write policy slips. Earlier project smoke checks also read the wrong retry trace field and used generated SQL tables as a proxy for retrieval quality.

Impact · The Catch2026-10-04

39 / 40

97.5% first-attempt and final reference-result matches (n = 40); enriched FAISS retrieval lifted dense MRR@7 from 0.678 to 0.888 and macro Recall@7 from 0.838 to 0.950.

Scope: Authored single-domain Formula 1 suite with explicit projection/order contracts; does not establish arbitrary-schema SQL accuracy.

Panel 02 · Engineering Contribution

Led technical implementation during my Generative AI internship at TransOrg Analytics (Pickl.AI): built the 9-node LangGraph workflow, enriched FAISS sub-schema retriever with table co-occurrence rules, read-only SQL policy guard, error-guided reflection retry path, Flask API, and independent October 2026 evaluation harness.

Panel 03 · System Architecture

  1. 01Intent router separates conversational turns from SQL generation before touching database schemas.
  2. 02Enriched FAISS schema retrieval plus table co-occurrence rules narrow 14 Formula 1 tables (excluding application system tables) into focused sub-schemas, lifting dense MRR@7 from 0.678 to 0.888.
  3. 03Application-level SQL guard parses statements to enforce read-only SELECT execution and outer row caps before querying TiDB Cloud.
  4. 04Error-guided reflection loop intercepts SQL execution errors (recovering 5 / 5 injected invalid-column probes in separate controlled tests) and exposes SQL traces alongside answers.

9-NODE LANGGRAPH READING ORDER · CLICK OR FOCUS ANY PANEL

From natural question to audited SQL — with an explicit flashback retry loop.

39 / 40 REF MATCHES · 5 / 5 PROBES
↺ FLASHBACK RETRY LOOP (07 TiDB Exception → 08 Error Reflection → 05 SQL Synthesis)5 / 5 injected invalid-column probes recovered (separate denominator)
NODE 08 · ERROR REFLECTION—FLASHBACK RETRY: feeds exact database error messages back to Node 05 to repair invalid columns or joins.

GUARD / EVIDENCE: 5 / 5 injected invalid-column probes recovered (reported separate from ordinary 39/40 eval).

F1InsightAI live application capture showing SQL results, RAG proxy diagnostics, and TiDB Cloud 701,694-row footer
Real live application capture (not an illustration). Hover or use Arrow keys to inspect the SQL, proxy panel, and bottom-right row-count footer at 2.0×.

Next Chapter · VS.02

Vigil

vs. The Null That Lied

Monochrome ink illustration of a machined black signal prism with two telemetry filaments crossing a single crimson calibration line