Question
An agent produced a gnarly 60-line SQL query (window functions, multiple CTEs, a correlated subquery) to compute monthly cohort retention for a leadership dashboard. It runs, returns plausible numbers, and you don't fully follow the windowing logic. You're about to wire it into a report executives will make decisions on. How do you verify it's correct before you ship — without just trusting it and without spending a day re-deriving it by hand?
Treat the AI’s output as a draft to verify, not an answer to trust. Name the specific flaw and the input that triggers it, say how you’d catch it — tests, edge cases, reading critically — and how you’d re-prompt or decompose to get it right.
Vibe coding: describe the solution in plain language (or narrate it) and the coach grades your approach. Generating runnable code from your description is coming next.