Validate AI Output — Catch Format Violations
Paste the response, get the verdict: real JSON parsing, missing-field detection, and a repair prompt for everything found.
The JSON won't parse and you can't see why. Deterministic cause-sniffing — trailing commas, single quotes, unclosed brackets — and the repair prompt that fixes it.
Broken JSON from a model fails silently in the worst way: the response looks complete, and the parser just says no. This setup loads the classic case — a contract extraction with a trailing comma before the closing brace — and shows the validator's parse-failure path: JSON.parse fails, the cause-sniffer identifies the likely culprit deterministically (trailing comma, single-quoted keys, or an unclosed bracket), and the repair prompt tells the model exactly what to fix while keeping every extracted value unchanged.
Paste the unparseable response
The validator attempts a real parse, then sniffs the cause when it fails.
Check the likely cause
Trailing comma, single quotes, unclosed bracket — named deterministically, not guessed.
Repair, don't regenerate
The repair prompt keeps every correct value and fixes only the syntax — regeneration would re-roll the data too.
Broken model JSON usually fails on one deterministic culprit: a trailing comma before } or ], single-quoted keys, or an unclosed bracket. The validator runs a real JSON.parse, and when it throws, the cause-sniffer names which of those three broke it — so an opaque 'Unexpected token' error becomes one specific, actionable syntax fix.
It repairs in place — it never regenerates, so your extracted values aren't re-rolled. Paste the model's raw unparseable response, and the validator hands you a REPAIR TASK / PROBLEMS FOUND / OUTPUT RULES prompt telling the model to 'keep everything that was already correct unchanged; fix only the problems listed.' You run that in ChatGPT, Claude, or Gemini.
It detects the cause; the model does the repair. In the browser, a genuine JSON.parse runs and names the culprit deterministically — trailing comma, single quotes, or unclosed bracket, weighted by a 50-point parse penalty. NewPrompt never silently rewrites the JSON; the actual fix happens when you paste the repair prompt into the assistant you choose. To prevent invalid JSON up front, use the JSON Output Prompt Builder.
Paste the response, get the verdict: real JSON parsing, missing-field detection, and a repair prompt for everything found.
Grade agent output the same way every time — a rubric scoring correctness, grounding, safety, tone, and completeness, with a pass threshold instead of a gut call.
Turn a failed case into a fix — diagnose where in the agent's flow it went wrong, categorize the failure, and point at the prompt, tool, or context that caused it.
Stop getting 'Sure, here is the JSON…' — the output-contract pattern that forces models to return only parseable JSON: schema, example, and a strict rule block.
Free text in, named fields out. The extraction prompt pattern that turns any unstructured text into consistent, parseable records.
Billing, Technical, Account, How-To, Feature Request — ticket triage with definitions that decide the borderline cases for the model.
Paste an AI's output and validate it against the expected format — with a repair prompt for every failure found.
Make any AI task return JSON your code can rely on — define the schema, force the model to it, validate every response, and diff the drift when a model update breaks the shape.