Files
sql-server-query-ai/kb/Placeholder SQL is dropped.md
ahmed mohammedandClaude Opus 4.7 8b42a0931c docs: karpathy-pattern wiki built from the spec, plan, design contract and decisions ledger
kb/ is its own wiki root: 34 pages across 7 categories, index.md catalog, log.md, AGENTS.md schema layer, and raw/ holding copies of README, the spec, the 13-task plan, the design master and the SDD ledger.

Every page cross-references 3 to 6 others and all 107 wikilinks resolve except two [["list"]] artefacts inside JSON snippets in the copied plan.

Kept separate from the repository root on purpose: its generated graph lands in kb/.ua/ instead of overwriting the code graph.

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
2026-09-22 12:14:05 +03:00

836 B

Decision: placeholder SQL is dropped, not rendered

With the new sql_to_run requirement, a report on a 100 KB statement came back containing SELECT ... FROM ... OPTION (MAXDOP 1);. A block nobody can paste is worse than no block: it reads as an instruction and fails on run.

dropPlaceholderSql nulls ellipsis SQL after schema validation, so the option simply gets no SqlBlock. The heuristic is marked as a deliberate shortcut: ... is not valid T-SQL, so a literal ellipsis inside a string literal would also be dropped, which costs a block and never invents one.

The model is also told upstream: when digestForModel sets `sql_truncated$, ShowPlan digest has already warning-ed the analyst out of offering a rewrite for a statement it never received.

Related: Option type and sql to run, Output token ceiling.